Curious what these log entries mean


#1

Hi all.
I’ve got a piston that I imported and modified from someone else and it does work great.
But I’m wondering what the log entries mean.
I normally get a notification saying what device has been left open with the correct device name but the other day I got a notification but instead of the device name it said “empty device” and noticed it says that in the log also.



#2

I think line 42 should just read “All windows are closed” and ditch the ternary operator.


#3

@eibyer’s solution is obviously the one to use.

But for reference, you are not populating the openwindows variable in the ELSE block, so the variable is empty hence the ‘null’ in the logs.


#4

Ah that makes sense now :slight_smile:
Thanks guys
Cheers @eibyer I’ll change that