It seems the assumption was made that "permissions" should be the only available option. I suggest allowing an options object to be passed through as the facebook sdk uses. There are some fairly common use cases where you need to set more than permissions: eg. auth_type='rerequest'.
If anyone requires this immediately, you can try this (note, I commented out default permissions, as I don't require it and didn't want to bother fixing it).
$facebook.login = function (args) {
//if(permissions==undefined) var permissions=$facebook.config("permissions");
var deferred=$q.defer();
return $facebook.promise.then(function(FB) {
FB.login(function(response) {
if(response.error) deferred.reject(response.error);
else deferred.resolve(response);
if(!$rootScope.$$phase) $rootScope.$apply();
}, args);
return deferred.promise;
});
};
It seems the assumption was made that "permissions" should be the only available option. I suggest allowing an options object to be passed through as the facebook sdk uses. There are some fairly common use cases where you need to set more than permissions: eg. auth_type='rerequest'.
If anyone requires this immediately, you can try this (note, I commented out default permissions, as I don't require it and didn't want to bother fixing it).