Class: LMSGraphQL::Resolvers::Canvas::GetCustomColor

Inherits:
CanvasBaseResolver
  • Object
show all
Defined in:
lib/lms_graphql/resolvers/canvas/get_custom_color.rb,
lib/lms_graphql/resolvers/canvas/get_custom_colors.rb

Instance Method Summary collapse

Instance Method Details

#resolve(id:, get_all: false) ⇒ Object



10
11
12
13
14
15
16
17
18
19
20
# File 'lib/lms_graphql/resolvers/canvas/get_custom_color.rb', line 10

def resolve(id:, asset_string:, get_all: false)
  result = context[:canvas_api].call("GET_CUSTOM_COLOR").proxy(
    "GET_CUSTOM_COLOR",
    {
      "id": id,
      "asset_string": asset_string            },
    nil,
    get_all,
  )
  get_all ? result : result.parsed_response
end