Sha256: ff66a0b49d875a524fa55f5064e299112ead2a8a1fc3651655fe4924797e2534
Contents?: true
Size: 597 Bytes
Versions: 19
Compression:
Stored size: 597 Bytes
Contents
<%= autogenerated_event_warning %> class LiveEvents::BaseEvent attr_accessor :payload def perform(event_payload) @payload = HashWithIndifferentAccess.new(event_payload['body']) end # Live events will use a canvas global ID (cross shard) for any ID's provided. This method will return the local ID. def local_canvas_id(id) id.to_i % 10_000_000_000_000 end def log_error(e) Rails.logger.error "Error processing Live Event: #{self.class.name}" Rails.logger.error "#{payload}" Rails.logger.error e.message Rails.logger.error e.backtrace.join("\n") end end
Version data entries
19 entries across 19 versions & 1 rubygems