Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
OHR Support
Manage
Activity
Members
Labels
Plan
Issues
97
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Projects
OHR Support
Commits
cd0ea44f
Commit
cd0ea44f
authored
13 years ago
by
Holger Just
Browse files
Options
Downloads
Patches
Plain Diff
[#822] Provide a default log_encoding even if the db column is not present yet
parent
4c0b1953
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
app/models/repository.rb
+8
-0
8 additions, 0 deletions
app/models/repository.rb
with
8 additions
and
0 deletions
app/models/repository.rb
+
8
−
0
View file @
cd0ea44f
...
...
@@ -200,6 +200,14 @@ class Repository < ActiveRecord::Base
encoding
.
blank?
?
'UTF-8'
:
encoding
end
# Provide a log encoding even if the column was not created yet
# It's used by 20100714111653_build_initial_journals_for_acts_as_journalized
# for initial journal creaetion of the changesets while the colum is only
# created by 20110228000000_add_repositories_log_encoding
def
log_encoding
read_attribute
(
:log_encoding
)
end
# Fetches new changesets for all repositories of active projects
# Can be called periodically by an external script
# eg. ruby script/runner "Repository.fetch_changesets"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment