fixed order of calling class methods