lib/twilio-ruby/rest/monitor/v1/alert.rb in twilio-ruby-5.4.2 vs lib/twilio-ruby/rest/monitor/v1/alert.rb in twilio-ruby-5.4.3

- old
+ new

@@ -77,13 +77,11 @@ # This operation lazily loads records as efficiently as possible until the limit # is reached. def each limits = @version.read_limits - page = self.page( - page_size: limits[:page_size], - ) + page = self.page(page_size: limits[:page_size],) @version.stream(page, limit: limits[:limit], page_limit: limits[:page_limit]).each {|x| yield x} end @@ -152,14 +150,11 @@ ## # Build an instance of AlertInstance # @param [Hash] payload Payload response from the API # @return [AlertInstance] AlertInstance def get_instance(payload) - AlertInstance.new( - @version, - payload, - ) + AlertInstance.new(@version, payload,) end ## # Provide a user friendly representation def to_s @@ -175,13 +170,11 @@ # @return [AlertContext] AlertContext def initialize(version, sid) super(version) # Path Solution - @solution = { - sid: sid, - } + @solution = {sid: sid,} @uri = "/Alerts/#{@solution[:sid]}" end ## # Fetch a AlertInstance @@ -193,15 +186,11 @@ 'GET', @uri, params, ) - AlertInstance.new( - @version, - payload, - sid: @solution[:sid], - ) + AlertInstance.new(@version, payload, sid: @solution[:sid],) end ## # Deletes the AlertInstance # @return [Boolean] true if delete succeeds, true otherwise @@ -248,24 +237,19 @@ 'response_headers' => payload['response_headers'], } # Context @instance_context = nil - @params = { - 'sid' => sid || @properties['sid'], - } + @params = {'sid' => sid || @properties['sid'],} end ## # Generate an instance context for the instance, the context is capable of # performing various actions. All instance actions are proxied to the context # @return [AlertContext] AlertContext for this AlertInstance def context unless @instance_context - @instance_context = AlertContext.new( - @version, - @params['sid'], - ) + @instance_context = AlertContext.new(@version, @params['sid'],) end @instance_context end ## \ No newline at end of file