Skip to content

Commit 7f99420

Browse files
HOTFIX: getCurrentJarFile(BetterReflectionClass)
Hotfix for BetterReflectionUtils#getCurrentJarFile(BetterReflectionClass), which now uses the given class parameter to determine whether it's running from Jar file or not.
1 parent 8dd88b0 commit 7f99420

File tree

3 files changed

+8
-20
lines changed

3 files changed

+8
-20
lines changed

pom.xml

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -29,24 +29,13 @@
2929

3030
<groupId>top.wavelength</groupId>
3131
<artifactId>Java-BetterReflection</artifactId>
32-
<version>1.3</version>
32+
<version>1.3.1</version>
3333

3434
<properties>
3535
<maven.compiler.source>1.8</maven.compiler.source>
3636
<maven.compiler.target>1.8</maven.compiler.target>
3737
</properties>
3838

39-
<distributionManagement>
40-
<snapshotRepository>
41-
<id>ossrh</id>
42-
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
43-
</snapshotRepository>
44-
<repository>
45-
<id>ossrh</id>
46-
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
47-
</repository>
48-
</distributionManagement>
49-
5039
<dependencies>
5140
<dependency>
5241
<groupId>org.junit.jupiter</groupId>
@@ -67,14 +56,13 @@
6756
<build>
6857
<plugins>
6958
<plugin>
70-
<groupId>org.sonatype.plugins</groupId>
71-
<artifactId>nexus-staging-maven-plugin</artifactId>
72-
<version>1.6.7</version>
59+
<groupId>org.sonatype.central</groupId>
60+
<artifactId>central-publishing-maven-plugin</artifactId>
61+
<version>0.6.0</version>
7362
<extensions>true</extensions>
7463
<configuration>
75-
<serverId>ossrh</serverId>
76-
<nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
77-
<autoReleaseAfterClose>true</autoReleaseAfterClose>
64+
<publishingServerId>central-wl</publishingServerId>
65+
<tokenAuth>true</tokenAuth>
7866
</configuration>
7967
</plugin>
8068
<plugin>

src/main/java/top/wavelength/betterreflection/BetterReflection.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ else if (version[i] < latestVersion[i])
166166
* @since 0.4
167167
*/
168168
public static String getVersion() {
169-
return "1.3";
169+
return "1.3.1";
170170
}
171171

172172
/**

src/main/java/top/wavelength/betterreflection/BetterReflectionUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public class BetterReflectionUtils {
2626
* @since 0.7
2727
*/
2828
public static File getCurrentJarFile(BetterReflectionClass<?> clasz) {
29-
if (!isRunningFromJar())
29+
if (!isRunningFromJar(clasz))
3030
return null;
3131
try {
3232
return new File(clasz.getProtectionDomain().getCodeSource().getLocation().toURI());

0 commit comments

Comments
 (0)