Disable login interceptor in messages service used in registration

This commit is contained in:
Mikołaj Pich 2020-08-23 16:52:06 +02:00
parent 47bb36a794
commit 7aa654605b
2 changed files with 4 additions and 4 deletions

View file

@ -177,8 +177,8 @@ class Scrapper {
normalizedSymbol, email, password,
LoginHelper(loginType, schema, host, normalizedSymbol, serviceManager.getCookieManager(), serviceManager.getLoginService()),
serviceManager.getRegisterService(),
serviceManager.getMessagesService(),
serviceManager.getStudentService(withLogin = false, studentInterceptor = false), // it is really needed?
serviceManager.getMessagesService(withLogin = false),
serviceManager.getStudentService(withLogin = false, studentInterceptor = false),
serviceManager.urlGenerator
)
}

View file

@ -130,8 +130,8 @@ class ServiceManager(
return client
}
fun getMessagesService(): MessagesService {
return getRetrofit(getClientBuilder(), urlGenerator.generate(UrlGenerator.Site.MESSAGES), gson = true).create()
fun getMessagesService(withLogin: Boolean = true): MessagesService {
return getRetrofit(getClientBuilder(loginIntercept = withLogin), urlGenerator.generate(UrlGenerator.Site.MESSAGES), gson = true).create()
}
fun getHomepageService(): HomepageService {