Removes useless code
Adds the possibility to set a default option value
Fixes rubocop offences