Commit 11be0bf1 by linxu

改进代码

parent 0e567a54
......@@ -33,9 +33,9 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
@Override
protected void configure(HttpSecurity http) throws Exception {
if (permit)
if (permit) {
http.httpBasic().and().authorizeRequests().anyRequest().permitAll();
else {
} else {
http.httpBasic().and()
.authorizeRequests().antMatchers("/actuator/**").permitAll().and()
.authorizeRequests().anyRequest().authenticated();
......
......@@ -156,9 +156,15 @@ public class MetaData extends BaseNode {
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
if (!super.equals(o)) return false;
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
if (!super.equals(o)) {
return false;
}
MetaData metaData = (MetaData) o;
return Objects.equals(node, metaData.node) &&
Objects.equals(path, metaData.path) &&
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment