Refactor to use class method