gitlab-org--gitlab-foss/app
Rémy Coutable 71672dfa6a
Return an ApplicationSetting in CurrentSettings
This replaces the use of fake_application_settings with
`::ApplicationSetting.build`_from_defaults. The reason is that
`fake_application_settings` doesn't have the custom accessors that
`ApplicationSetting` has, e.g. `#commit_email_hostname`, thus this
can lead to unexpected `nil` values which comes from the database
column instead of `.default_commit_email_hostname` returned by
`ApplicationSetting#commit_email_hostname`.

Using `::ApplicationSetting.build_from_defaults` should be safe as it
doesn't try to `INSERT` a DB record, in contrary to
`::ApplicationSetting.create_from_defaults` which we used to use, and
which created issues that the introduction of
`fake_application_settings` tried to resolve (575dced5).

Signed-off-by: Rémy Coutable <remy@rymai.me>
2018-12-19 11:24:53 +01:00
..
assets Add explanatory help text to text inputs on user profile settings page 2018-12-18 14:38:21 +00:00
controllers Merge branch 'reduce-diff-with-ee-in-protected_refs_controller' into 'master' 2018-12-18 16:54:44 +00:00
finders Hide confidential events in ruby 2018-12-17 18:47:53 +01:00
graphql Suggests issues when typing title 2018-11-27 15:10:40 +00:00
helpers Backport of 8810-fix-weight-sort 2018-12-18 14:35:40 -06:00
mailers Add List-Id to notification emails 2018-12-13 11:15:48 +00:00
models Return an ApplicationSetting in CurrentSettings 2018-12-19 11:24:53 +01:00
policies Add a missing policy allowance in GroupPolicy 2018-12-18 13:53:46 +01:00
presenters Move code to presenter 2018-12-17 09:51:53 +13:00
serializers Merge branch '54786-mr-empty-file-display' into 'master' 2018-12-15 12:21:54 +00:00
services Merge branch '51485-new-issue-labels-note' into 'master' 2018-12-18 10:08:44 +00:00
uploaders
validators Merge branch 'ce-jej/group-saml-sso-button-link-description' into 'master' 2018-12-08 03:02:18 +00:00
views Merge branch '54146-fix-calendar-query' into 'master' 2018-12-19 10:03:44 +00:00
workers Merge branch '54650-send-an-email-to-project-owners-when-a-mirror-update-fails' into 'master' 2018-12-12 13:31:53 +00:00