summaryrefslogtreecommitdiff
path: root/lib/gitlab
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2016-08-04 23:44:27 +0800
committerLin Jen-Shin <godfat@godfat.org>2016-08-04 23:44:27 +0800
commit984367f957c8f8d02fa82b08817e2f2f318c6bff (patch)
tree6f18804966e10c58473094c94cb8c2a0626d8065 /lib/gitlab
parent80671bf75cdac3f50615253b058fa04da6235a4f (diff)
downloadgitlab-ce-984367f957c8f8d02fa82b08817e2f2f318c6bff.tar.gz
Move those builders to their own namespace, feedback:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5620#note_13540099
Diffstat (limited to 'lib/gitlab')
-rw-r--r--lib/gitlab/data_builder/build_data_builder.rb (renamed from lib/gitlab/build_data_builder.rb)6
-rw-r--r--lib/gitlab/data_builder/note_data_builder.rb (renamed from lib/gitlab/note_data_builder.rb)6
-rw-r--r--lib/gitlab/data_builder/push_data_builder.rb (renamed from lib/gitlab/push_data_builder.rb)6
3 files changed, 12 insertions, 6 deletions
diff --git a/lib/gitlab/build_data_builder.rb b/lib/gitlab/data_builder/build_data_builder.rb
index 9f45aefda0f..5175645e238 100644
--- a/lib/gitlab/build_data_builder.rb
+++ b/lib/gitlab/data_builder/build_data_builder.rb
@@ -1,6 +1,8 @@
module Gitlab
- class BuildDataBuilder
- class << self
+ module DataBuilder
+ module BuildDataBuilder
+ module_function
+
def build(build)
project = build.project
commit = build.pipeline
diff --git a/lib/gitlab/note_data_builder.rb b/lib/gitlab/data_builder/note_data_builder.rb
index 8bdc89a7751..12ae1b99f9c 100644
--- a/lib/gitlab/note_data_builder.rb
+++ b/lib/gitlab/data_builder/note_data_builder.rb
@@ -1,6 +1,8 @@
module Gitlab
- class NoteDataBuilder
- class << self
+ module DataBuilder
+ module NoteDataBuilder
+ module_function
+
# Produce a hash of post-receive data
#
# For all notes:
diff --git a/lib/gitlab/push_data_builder.rb b/lib/gitlab/data_builder/push_data_builder.rb
index c8f12577112..f0cad51dd36 100644
--- a/lib/gitlab/push_data_builder.rb
+++ b/lib/gitlab/data_builder/push_data_builder.rb
@@ -1,6 +1,8 @@
module Gitlab
- class PushDataBuilder
- class << self
+ module DataBuilder
+ module PushDataBuilder
+ module_function
+
# Produce a hash of post-receive data
#
# data = {