Makjor refactor