fixing 'no-self-use' and attempting to refactor