Commit e8584548 authored by Douglas Barbosa Alexandre's avatar Douglas Barbosa Alexandre
Browse files

Handle exceptions when writing to .git/config

parent 524cf7684def
......@@ -1440,6 +1440,9 @@ def after_rename_repo
def write_repository_config(key, value, prefix: :gitlab)
key = [prefix, key].compact.join('.')
repo.config[key] = value
rescue Gitlab::Git::Repository::NoRepository => e
Rails.logger.error("Error writing key #{key} to .git/config for project #{full_path} (#{id}): #{e.message}.")
nil
end
def rename_repo_notify!
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment