debian-mirror-gitlab/app/helpers/json_helper.rb

15 lines
335 B
Ruby
Raw Normal View History

2023-01-13 00:05:48 +05:30
# frozen_string_literal: true
module JsonHelper
# These two JSON helpers are short-form wrappers for the Gitlab::Json
# class, which should be used in place of .to_json calls or calls to
# the JSON class.
2023-04-23 21:23:45 +05:30
def json_generate(...)
Gitlab::Json.generate(...)
2023-01-13 00:05:48 +05:30
end
2023-04-23 21:23:45 +05:30
def json_parse(...)
Gitlab::Json.parse(...)
2023-01-13 00:05:48 +05:30
end
end