Changed order of commands

Moved def no_action to a higher level