fixed call to a non onject error