Referenced object error

Hello, I am trying to get the reference level from a linked object using this post’s method: Query Level of Linked Element

But I keep getting this error.
dynamo_referencedobject
IN[0] is just a list of elements from a linked revit and IN[1] is the doc of said linked revit. I am not sure if something in the code changed between when the post was made and now or if it is a problem from my linked file.

Any feedback would be appreciated.

I reloaded the linked files and the error went away but now this error shows:
dynamo_nonetype

Same code as before except instead of doc[0] in the append line, it is just doc (since I had an error that doc was unsubscriptable)

Hi @kennyb6

Please show us complete graph with all the previews turned on.