Skip to content

Commit

Permalink
Removed references to spigotmc. eco will now check polymart for updates
Browse files Browse the repository at this point in the history
  • Loading branch information
WillFP committed Sep 19, 2021
1 parent 396f4da commit fcc7f82
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 12 deletions.
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# Information for development

## Javadoc
The 6.0.0 Javadoc can be found [here](https://javadoc.jitpack.io/com/willfp/eco/6.0.0/javadoc/)
The 6.8.0 Javadoc can be found [here](https://javadoc.jitpack.io/com/willfp/eco/6.8.0/javadoc/)

## Plugin Information

Expand All @@ -31,7 +31,6 @@ depend:
eco is available from any of these places:
- [GitHub](https://github.com/Auxilor/eco/releases)
- [Spigot](https://www.spigotmc.org/resources/eco.87955/)
- [Polymart](https://polymart.org/resource/eco.773)
- [Build it locally](https://github.com/Auxilor/eco#build-locally).
Expand Down Expand Up @@ -72,7 +71,7 @@ Maven:
</dependency>
```

Replace `Tag` with a release tag for eco, eg `6.0.0`.
Replace `Tag` with a release tag for eco, eg `6.8.0`.

## Build locally:

Expand Down
16 changes: 8 additions & 8 deletions eco-api/src/main/java/com/willfp/eco/core/EcoPlugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
@SuppressWarnings("unused")
public abstract class EcoPlugin extends JavaPlugin {
/**
* The spigot resource ID of the plugin.
* The polymart resource ID of the plugin.
*/
@Getter
private final int resourceId;
Expand Down Expand Up @@ -169,14 +169,14 @@ public abstract class EcoPlugin extends JavaPlugin {
private final ProxyFactory proxyFactory;

/**
* Create a new plugin without a specified color, proxy support, spigot, or bStats.
* Create a new plugin without a specified color, proxy support, polymart, or bStats.
*/
protected EcoPlugin() {
this("&f");
}

/**
* Create a new plugin without proxy support, spigot, or bStats.
* Create a new plugin without proxy support, polymart, or bStats.
*
* @param color The color.
*/
Expand All @@ -186,7 +186,7 @@ protected EcoPlugin(@NotNull final String color) {


/**
* Create a new plugin unlinked to spigot and bStats.
* Create a new plugin unlinked to polymart and bStats.
*
* @param proxyPackage The package where proxy implementations are stored.
* @param color The color of the plugin (used in messages, using standard formatting)
Expand All @@ -199,7 +199,7 @@ protected EcoPlugin(@NotNull final String proxyPackage,
/**
* Create a new plugin without proxy or extension support.
*
* @param resourceId The spigot resource ID for the plugin.
* @param resourceId The polymart resource ID for the plugin.
* @param bStatsId The bStats resource ID for the plugin.
* @param color The color of the plugin (used in messages, using standard formatting)
*/
Expand All @@ -212,7 +212,7 @@ protected EcoPlugin(final int resourceId,
/**
* Create a new plugin without proxy support.
*
* @param resourceId The spigot resource ID for the plugin.
* @param resourceId The polymart resource ID for the plugin.
* @param bStatsId The bStats resource ID for the plugin.
* @param color The color of the plugin (used in messages, using standard formatting)
* @param supportingExtensions If the plugin supports extensions.
Expand All @@ -227,7 +227,7 @@ protected EcoPlugin(final int resourceId,
/**
* Create a new plugin without extension support.
*
* @param resourceId The spigot resource ID for the plugin.
* @param resourceId The polymart resource ID for the plugin.
* @param bStatsId The bStats resource ID for the plugin.
* @param proxyPackage The package where proxy implementations are stored.
* @param color The color of the plugin (used in messages, using standard formatting)
Expand All @@ -242,7 +242,7 @@ protected EcoPlugin(final int resourceId,
/**
* Create a new plugin.
*
* @param resourceId The spigot resource ID for the plugin.
* @param resourceId The polymart resource ID for the plugin.
* @param bStatsId The bStats resource ID for the plugin.
* @param proxyPackage The package where proxy implementations are stored.
* @param color The color of the plugin (used in messages, using standard formatting)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@ public UpdateChecker(@NotNull final EcoPlugin plugin) {
public void getVersion(@NotNull final Consumer<? super String> consumer) {
this.getPlugin().getScheduler().runAsync(() -> {
try {
InputStream inputStream = new URL("https://api.spigotmc.org/legacy/update.php?resource=" + this.getPlugin().getResourceId()).openStream();
InputStream inputStream = new URL(
"https://api.polymart.org/v1/getResourceInfoSimple?key=version&resource_id=" + this.getPlugin().getResourceId()
).openStream();
Scanner scanner = new Scanner(inputStream);

if (scanner.hasNext()) {
Expand Down

0 comments on commit fcc7f82

Please sign in to comment.