fixed preexecute and some temporary things in the rest controller