Version 2.13.0; Send authorization

This commit is contained in:
James Barnsley
2017-02-21 19:54:00 +13:00
parent f4fcd2521d
commit da5aa367b1
2 changed files with 3 additions and 21 deletions

View File

@ -12,7 +12,7 @@ from handlers import WebsocketHandler, HttpHandler
from core import IrisCore
logger = logging.getLogger(__name__)
__version__ = '2.12.1'
__version__ = '2.13.0'
##
# Core extension class

View File

@ -148,7 +148,7 @@ const PusherMiddleware = (function(){
request('deliver_message', action)
.then(
response => {
store.dispatch( uiActions.createNotification(response.message) )
store.dispatch( uiActions.createNotification('Message delivered') )
}
)
break
@ -234,25 +234,7 @@ const PusherMiddleware = (function(){
)
break;
case 'PUSHER_SEND_AUTHORIZATION':
request('send_authorization', {
recipient_connection_id: action.recipient_connection_id,
authorization: action.authorization,
me: action.me
})
.then(
response => {
if (response.error){
console.error(response.error)
return false
}
store.dispatch( uiActions.createNotification('Authorization sent') )
}
)
break;
case 'PUSHER_SEND_AUTHORIZATION':
case 'PUSHER_SPOTIFY_AUTHORIZATION':
if( window.confirm('Spotify authorization for user '+action.me.id+' received. Do you want to import?') ){
// remove any existing authentication