Cleaned code by Rubocop standards