You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
asciinema.org/app/services/asciicast_updater.rb

19 lines
326 B
Ruby

class AsciicastUpdater
def update(asciicast, attributes)
asciicast.attributes = attributes
need_snapshot_update = asciicast.snapshot_at_changed?
if asciicast.save
if need_snapshot_update
AsciicastSnapshotUpdater.new.update(asciicast)
end
true
else
false
end
end
end