hpi-swt2/vm-portal

Move default AppSettings to seeds

Closed this issue · 1 comments

Currently, the model file app/models/app_setting.rb contains default app settings in the def self.instance method. which might not be the ideal place for them.
If no AppSettings model was seeded, the defaults should most likely be '' (or whatever is defined as the default in db/schema.rb.

I would assume that sane defaults should be included in a db/seeds.rb file.

It seems that some of the defaults in app/models/app_setting.rb (e.g. example@email.com or MyUserName) were used more as placeholders for fields indicating the required input. This is a use case for the HTML placeholder attribute.

Fixed in #469