Removing unneeded local variable