Skip to content

Commit

Permalink
run formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
jschwarz2030 committed Nov 23, 2023
1 parent 635fe61 commit de72188
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
4 changes: 3 additions & 1 deletion app/org/maproulette/Config.scala
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,9 @@ class Config @Inject() (implicit val configuration: Configuration) {
this.config.getOptional[Int](Config.KEY_TASK_RESET).getOrElse(Config.DEFAULT_TASK_RESET)
lazy val signIn: Boolean =
this.config.getOptional[Boolean](Config.KEY_SIGNIN).getOrElse(Config.DEFAULT_SIGNIN)
lazy val systemNoticesUrl: String = this.config.getOptional[String](Config.KEY_SYSTEM_NOTICES_URL).getOrElse(Config.DEFAULT_SYSTEM_NOTICES_URL)
lazy val systemNoticesUrl: String = this.config
.getOptional[String](Config.KEY_SYSTEM_NOTICES_URL)
.getOrElse(Config.DEFAULT_SYSTEM_NOTICES_URL)

//caching properties
lazy val cacheType: String =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@ class NotificationController @Inject() (
val url = config.systemNoticesUrl

if (!url.isEmpty) {
wsClient.url(url)
wsClient
.url(url)
.withHttpHeaders(
"Accept" -> "application/json"
)
Expand All @@ -143,7 +144,11 @@ class NotificationController @Inject() (
InternalServerError(Json.toJson(s"An error occurred: ${e.getMessage}"))
}
} else {
Future.successful(InternalServerError(Json.toJson("An error occurred: System notices not set up on this server")))
Future.successful(
InternalServerError(
Json.toJson("An error occurred: System notices not set up on this server")
)
)
}
}
}

0 comments on commit de72188

Please sign in to comment.