diff options
author | Ash McKenzie <amckenzie@gitlab.com> | 2018-09-07 10:59:13 +1000 |
---|---|---|
committer | Ash McKenzie <amckenzie@gitlab.com> | 2018-09-07 10:59:24 +1000 |
commit | 631430b2fd5f581637a66580ee9a56a508cc7ca4 (patch) | |
tree | 4d328509bafb493731a1a725d8ee3b0b03d240a9 /lib | |
parent | 493646938cad8f99f5420ec578689e112515c5d7 (diff) | |
download | gitlab-shell-631430b2fd5f581637a66580ee9a56a508cc7ca4.tar.gz |
New HTTPCodes module
Diffstat (limited to 'lib')
-rw-r--r-- | lib/http_codes.rb | 5 | ||||
-rw-r--r-- | lib/http_helper.rb | 4 |
2 files changed, 9 insertions, 0 deletions
diff --git a/lib/http_codes.rb b/lib/http_codes.rb new file mode 100644 index 0000000..24b3b5a --- /dev/null +++ b/lib/http_codes.rb @@ -0,0 +1,5 @@ +module HTTPCodes + HTTP_SUCCESS = '200'.freeze + HTTP_UNAUTHORIZED = '401'.freeze + HTTP_NOT_FOUND = '404'.freeze +end diff --git a/lib/http_helper.rb b/lib/http_helper.rb index 62d0c51..1e75833 100644 --- a/lib/http_helper.rb +++ b/lib/http_helper.rb @@ -1,4 +1,8 @@ +require_relative 'http_codes' + module HTTPHelper + include HTTPCodes + READ_TIMEOUT = 300 protected |