updates to fix variable declarations