Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
195d8b50
Commit
195d8b50
authored
Apr 05, 2017
by
Douglas Barbosa Alexandre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Does not use magic finders since they are deprecated in AR 5
parent
d77aaa35
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
4 deletions
+4
-4
lib/gitlab/geo/file_downloader.rb
lib/gitlab/geo/file_downloader.rb
+1
-1
lib/gitlab/geo/file_uploader.rb
lib/gitlab/geo/file_uploader.rb
+1
-1
lib/gitlab/geo/lfs_downloader.rb
lib/gitlab/geo/lfs_downloader.rb
+1
-1
lib/gitlab/geo/lfs_uploader.rb
lib/gitlab/geo/lfs_uploader.rb
+1
-1
No files found.
lib/gitlab/geo/file_downloader.rb
View file @
195d8b50
...
...
@@ -13,7 +13,7 @@ module Gitlab
# Subclasses should return the number of bytes downloaded,
# or nil or -1 if a failure occurred.
def
execute
upload
=
Upload
.
find_by
_id
(
object_db_id
)
upload
=
Upload
.
find_by
(
id:
object_db_id
)
return
unless
upload
.
present?
transfer
=
::
Gitlab
::
Geo
::
FileTransfer
.
new
(
object_type
.
to_sym
,
upload
)
...
...
lib/gitlab/geo/file_uploader.rb
View file @
195d8b50
...
...
@@ -9,7 +9,7 @@ module Gitlab
end
def
execute
recorded_file
=
Upload
.
find_by
_id
(
object_db_id
)
recorded_file
=
Upload
.
find_by
(
id:
object_db_id
)
return
error
unless
recorded_file
&
.
exist?
return
error
unless
valid?
(
recorded_file
)
...
...
lib/gitlab/geo/lfs_downloader.rb
View file @
195d8b50
...
...
@@ -2,7 +2,7 @@ module Gitlab
module
Geo
class
LfsDownloader
<
FileDownloader
def
execute
lfs_object
=
LfsObject
.
find_by
_id
(
object_db_id
)
lfs_object
=
LfsObject
.
find_by
(
id:
object_db_id
)
return
unless
lfs_object
.
present?
transfer
=
::
Gitlab
::
Geo
::
LfsTransfer
.
new
(
lfs_object
)
...
...
lib/gitlab/geo/lfs_uploader.rb
View file @
195d8b50
...
...
@@ -2,7 +2,7 @@ module Gitlab
module
Geo
class
LfsUploader
<
FileUploader
def
execute
lfs_object
=
LfsObject
.
find
(
object_db_id
)
lfs_object
=
LfsObject
.
find
_by
(
id:
object_db_id
)
return
error
unless
lfs_object
.
present?
return
error
if
message
[
:sha256
]
!=
lfs_object
.
oid
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment