mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-08-29 03:06:45 +08:00
Polish
This commit is contained in:
parent
2b47d608f3
commit
fdd79907e9
@ -85,14 +85,12 @@ public class AgentTasksEnhancer implements Action<Project> {
|
||||
if (loaded != null) {
|
||||
CodeSource source = loaded.getProtectionDomain().getCodeSource();
|
||||
if (source != null) {
|
||||
File agent;
|
||||
try {
|
||||
agent = new File(source.getLocation().toURI());
|
||||
return new File(source.getLocation().toURI());
|
||||
}
|
||||
catch (URISyntaxException ex) {
|
||||
agent = new File(source.getLocation().getPath());
|
||||
return new File(source.getLocation().getPath());
|
||||
}
|
||||
return agent;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user