fix missing private variables and missing statement

sorry was in a rush to go home :)