guestbook.rb
# Update when a guest signed the book
Update when a guest signed the book
Update when a guest signed the book
def update(name_to_update)
        if @signatures.key?(name_to_update)
            @signatures[name_to_update] = Time.now
        else
            raise RuntimeError.new "#{name_to_update} is not in the book"
        end
        return "Successfully updated #{name_to_update} at #{@signatures[name_to_update]}"
    end
def update ( name_to_update ) if @signatures . key? ( name_to_update ) @signatures [ name_to_update ] = Time . now else raise RuntimeError . new "#{name_to_update} is not in the book" end return "Successfully updated #{name_to_update} at #{@signatures[name_to_update]}" end
Update when a guest signed the book
Update when a guest signed the book
name_to_update
<not_specific>