Add a small fix in the geonode_authorize_layer function.