This code is not a code of honor. No highly esteemed function is executed here... nothing subsettable is here. What is here is dangerous and repulsive to us. This message is a warning about danger.
The danger is of type 'closure'... it increases when you attempt subsetting... the center of danger is here...
df[1]... and it surrounds us. The danger is still present, in your R session, as it was in ours. The danger is to the code, and it can crash your script.
The form of the danger is an emanation of:
Error: object of type 'closure' is not subsettable
The danger is unleashed only if you substantially disturb this function by treating it as a vector or list. This function is best called with parentheses and left unsubsetted.