bugfix variable assigenment