Merge branch 'doc-for-all-fix' into 'dev'

Added all paths to swagger documentation

See merge request sa4-2020/the-sanmarinoes/backend!29
This commit is contained in:
Claudio Maggioni 2020-03-09 23:13:36 +01:00
commit 507f523991

View file

@ -8,6 +8,7 @@ import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import springfox.documentation.builders.ApiInfoBuilder;
import springfox.documentation.builders.PathSelectors;
import springfox.documentation.builders.RequestHandlerSelectors;
import springfox.documentation.service.ApiInfo;
import springfox.documentation.service.ApiKey;
@ -67,10 +68,7 @@ public class SpringFoxConfig {
* @return A predicate that tests whether a path must be included or not
*/
private Predicate<String> paths() {
return regexPredicate("/auth.*")
.or(regexPredicate("/room.*"))
.or(regexPredicate("/register.*"))
.or(regexPredicate("/"));
return PathSelectors.any()::apply;
}
/**