Git Product home page Git Product logo

Comments (3)

Wundero avatar Wundero commented on June 17, 2024

I just committed a fix that allows null for the source as far as I can tell (I will test to see if it actually works in a moment, and push any fixes if it doesn't). I will push another update soon but I have been super busy recently. I will close this issue once I've verified that null sources and observers work.

In the future though, when Contexts are properly pushed, you could have a source because displayname can be per player. Might be interesting to look into ;)

from placeholderapi.

Wundero avatar Wundero commented on June 17, 2024

Ok so it looks like I've got some more internal issues, so I am looking into that now. From now on, annotated methods will have to specify that they support nullable sources with the @Nullable annotation. I will update my internals accordingly.

from placeholderapi.

Wundero avatar Wundero commented on June 17, 2024

Alright, I just pushed another commit that seems to support null sources and observers as much as I can internally. Parameters with the @Nullable annotation CAN be null, while parameters without it are ALWAYS present. The token parameter only uses the annotation if it is a String, because it doesn't make sense to have a null reference for an Optional<String>.

This should fix this issue but I should point out that many of the placeholders I have are dependent on having a source (such as player or rank), so there isn't too much you can do with this. I might work on the economy placeholder to support balance ranks that are source-independent, but I don't have enough time today so maybe another day.

from placeholderapi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.