Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use plugable not authorized page #525

Merged
merged 1 commit into from Nov 6, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion module-code/app/securesocial/controllers/ViewsPlugin.scala
Expand Up @@ -161,7 +161,7 @@ object ViewTemplates {
securesocial.views.html.passwordChange(form)
}

def getNotAuthorizedPage(implicit request: RequestHeader, lang: Lang): Html = {
override def getNotAuthorizedPage(implicit request: RequestHeader, lang: Lang): Html = {
securesocial.views.html.notAuthorized()
}
}
Expand Down
2 changes: 1 addition & 1 deletion module-code/app/securesocial/core/SecureSocial.scala
Expand Up @@ -44,7 +44,7 @@ trait SecureSocial[U] extends Controller {
*/
protected val notAuthenticatedJson = Unauthorized(Json.toJson(Map("error" -> "Credentials required"))).as(JSON)
protected val notAuthorizedJson = Forbidden(Json.toJson(Map("error" -> "Not authorized"))).as(JSON)
protected def notAuthorizedPage()(implicit request: RequestHeader): Html = securesocial.views.html.notAuthorized()
protected def notAuthorizedPage()(implicit request: RequestHeader): Html = env.viewTemplates.getNotAuthorizedPage

protected def notAuthenticatedResult[A](implicit request: Request[A]): Future[Result] = {
Future.successful {
Expand Down