Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'doc/development/rails_initializers.md')
-rw-r--r--doc/development/rails_initializers.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/development/rails_initializers.md b/doc/development/rails_initializers.md
index 9bf4109f1cb..68f3c07e45a 100644
--- a/doc/development/rails_initializers.md
+++ b/doc/development/rails_initializers.md
@@ -24,13 +24,13 @@ Some examples where you would need to do this are:
## Database connections in initializers
Ideally, database connections are not opened from Rails initializers. Opening a
-database connection (e.g. checking the database exists, or making a database
+database connection (for example, checking the database exists, or making a database
query) from an initializer means that tasks like `db:drop`, and
`db:test:prepare` will fail because an active session prevents the database from
being dropped.
To help detect when database connections are opened from initializers, we now
-warn in stderr. For example:
+warn in `STDERR`. For example:
```shell
DEPRECATION WARNING: Database connection should not be called during initializers (called from block in <module:HasVariable> at app/models/concerns/ci/has_variable.rb:22)