GithubHelp home page GithubHelp logo

Comments (7)

cmeeren avatar cmeeren commented on July 27, 2024 1

The helper function makes sense to me. 🙂

I'd call it requireNotNull (as OP suggested) instead of requireNonNull though, to fit with other functions (e.g. notEqualTo) (and in my mind it sounds better), but I certainly don't want to create a fuss over the difference.

from fstoolkit.errorhandling.

cmeeren avatar cmeeren commented on July 27, 2024

Would Option.ofObj >> Result.requireSome suit your purposes?

from fstoolkit.errorhandling.

demystifyfp avatar demystifyfp commented on July 27, 2024

@cmeeren It'd help. But I feel @danyx23 requirement makes sense in the context of other such helper functions currently available in the library. What do you recommend?

One suggestion on the name of the function, can we have it as requireNonNull?

from fstoolkit.errorhandling.

danyx23 avatar danyx23 commented on July 27, 2024

Yes I think while Option.ofObj >> Result.requireSome is also a nice way it would be good to have something specific for this rather common case that is a bit more obvious when reading the code.

I am totally fine with requireNotNull. I'll send a PR and then we can discuss any further details there. Thansk!

from fstoolkit.errorhandling.

danyx23 avatar danyx23 commented on July 27, 2024

Sent a PR. Let me know what you think. I only realized in the PR that there are some whitespace changes because my editor is set to remove trailing whitespace and doesn't show whitespace diffs when staging changes - hope you don't mind.

from fstoolkit.errorhandling.

demystifyfp avatar demystifyfp commented on July 27, 2024

Thanks, @danyx23 for the PR. I've merged the changes and published the new version 1.2.3. Can you verify the changes and close this issue?

from fstoolkit.errorhandling.

danyx23 avatar danyx23 commented on July 27, 2024

Looks good. I have some strange issue with the update of the nuget file in the project that I am using this but the assembly has the new code and everything should work so I'm closing the issue.

from fstoolkit.errorhandling.

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.