moved class method to scope