kennedyoliveira/pastebin4j

Version in maven central is not the same as this repository

Closed this issue · 4 comments

I tried to use this project and it didn't work at all, it is because the version in maven central is an old one compared to this repository. This repository seems to work with https, but the older build doesn't.

This is the class decompiled using the latest version in maven central (1.2.0)

//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//

package com.github.kennedyoliveira.pastebin4j.api;

import org.jetbrains.annotations.Nullable;

class PasteUtil {
    /** @deprecated */
    private PasteUtil() {
    }

    public static String getPasteKeyFromUrl(@Nullable String url) {
        if(url == null) {
            return null;
        } else if(!url.contains("http://pastebin.com/")) {
            throw new IllegalArgumentException("Not a valid paste bin url!");
        } else {
            return url.substring(url.indexOf("http://pastebin.com/") + "http://pastebin.com/".length());
        }
    }
}

Hey @jaime29010, thanks for the feedback, i'm going to check to see what happens and if needed, release another version on maven central.

I re-released the version 1.2 as 1.2.1, this should take some time until the jars are synced on maven, so wait like 1 to 2 hours and try again.

Thanks, now it works.

@jaime29010, I'm glad it's working now, if you have any feedback, please open an issue.