Fixed JS declaration error, small key changes