@@ -123,14 +123,16 @@ public Versioning version(String groupId, String artifactId) {
123
123
* @since 1.0.0
124
124
*/
125
125
public int store (String groupId , String artifactId , String version ) throws IOException {
126
- File docFile = Paths .get (LOCAL_PATH + File .separator + groupId + File .separator + artifactId + File .separator + version ).toFile ();
126
+ File docFile = Paths .get (LOCAL_PATH + File .separator +
127
+ groupId + File .separator + artifactId + File .separator + version ).toFile ();
127
128
if (docFile .exists ()) {
128
129
return 202 ;
129
130
}
130
131
131
132
String rep = repositoryUrl (groupId );
132
133
String jarName = artifactId + "-" + version + "-javadoc.jar" ;
133
- String url = String .format ("%s/%s/%s/%s/%s" , rep , groupId .replace ("." , "/" ), artifactId , version , jarName );
134
+ String url = String .format ("%s/%s/%s/%s/%s" ,
135
+ rep , groupId .replace ("." , "/" ), artifactId , version , jarName );
134
136
log .info ("download javadoc. url={}" , url );
135
137
ResponseEntity <byte []> resp = null ;
136
138
try {
@@ -145,7 +147,8 @@ public int store(String groupId, String artifactId, String version) throws IOExc
145
147
if (!resp .getStatusCode ().is2xxSuccessful ()) {
146
148
return 500 ;
147
149
}
148
- Path versionPath = Paths .get (JAR_PATH + File .separator + groupId + File .separator + artifactId + File .separator + version );
150
+ Path versionPath = Paths .get (JAR_PATH + File .separator +
151
+ groupId + File .separator + artifactId + File .separator + version );
149
152
Path jarPath = versionPath .resolve (jarName );
150
153
versionPath .toFile ().mkdirs ();
151
154
Files .write (jarPath , resp .getBody ());
0 commit comments