* change can_delete to can_cancel, and don't cehck for start_at anymore

This commit is contained in:
Seth Call 2014-07-10 11:38:17 -05:00
parent f2975c8838
commit 3a5d146ef3
2 changed files with 3 additions and 3 deletions

View File

@ -392,8 +392,8 @@ module JamRuby
active_music_session && active_music_session.mount
end
def can_delete? user
self.creator == user && self.started_at.nil?
def can_cancel? user
self.creator == user
end
def legal_policy_url

View File

@ -240,7 +240,7 @@ class ApiMusicSessionsController < ApiController
def destroy
begin
music_session = MusicSession.find(params[:id])
if music_session.can_delete? current_user
if music_session.can_cancel? current_user
Notification.send_scheduled_session_cancelled music_session
music_session.canceled = true
music_session.save