User can only sign out their own session

This commit is contained in:
Brenda Wallace
2017-02-13 20:08:31 +13:00
parent d11e6f484a
commit e6b23262da

View File

@@ -29,7 +29,7 @@ class AuthenticationsController < ApplicationController
# DELETE /authentications/1
def destroy
@authentication = Authentication.find(params[:id])
@authentication = Authentication.find_by(id: params[:id], member: current_member)
@authentication.destroy
respond_to do |format|