Fix rubocop warning 'SelfAssignment'