Remove some unneccesary code

It's not neccesary to pop lua values from registered functions.