CLUB-682, prioritize errors and refactor code, fix save() function