Fixed order problem in the variable review

Fixed ordering problem in variable review, and cleaned up variable
passing between functions.