Skip to content

Commit

Permalink
test 1
Browse files Browse the repository at this point in the history
  • Loading branch information
Ufuoma-Daniel committed Jun 11, 2021
1 parent 9a25498 commit 9dc810c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/connectors/CompanyHouseConnector.scala
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class CompanyHouseConnector @Inject()(appConfig: FrontendAppConfig, http: HttpCl
}

def validateCRN(data: CompanyDetails)(implicit ec: ExecutionContext): Future[Option[Boolean]] = {
implicit val hc: HeaderCarrier = HeaderCarrier().withExtraHeaders(("Authorization", appConfig.companyHouseRequestAuth))
implicit val hc: HeaderCarrier = HeaderCarrier()
val httpClient = if (appConfig.proxyRequired) proxyHttp else http

httpClient.GET(appConfig.companyHouseRequestUrl + data.companyReferenceNumber, headers = Seq("Authorization" -> appConfig.companyHouseRequestAuth))
Expand All @@ -52,7 +52,7 @@ class CompanyHouseConnector @Inject()(appConfig: FrontendAppConfig, http: HttpCl
logger.error(s"[CompanyHouseConnector][validateCRN] request limit exceeded - $response")
None
case _ =>
logger.error(s"[CompanyHouseConnector][validateCRN] $response")
logger.error(s"[CompanyHouseConnector][validateCRN] ${response.body}")
None
}
}.recover{
Expand Down

0 comments on commit 9dc810c

Please sign in to comment.