Fixed problem with method parameter when moved inside class