Problem/Motivation

The DX of the Registrant::getWaitlist() and Registrant::setWaitlist() methods is poor. The documentation mentions that an integer value should be passed, but in fact a string value "0" indicates that a registrant is not on the waitlist, and "1" indicates they are on the waitlist.

Proposed resolution

Let's use a boolean value.

API changes

This changes the types of these methods. We should throw deprecation warnings in 2.0.x, and enforce the boolean type in 3.0.x.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

pfrenssen created an issue. See original summary.

muriqui made their first commit to this issue’s fork.

muriqui’s picture

Status: Active » Needs review
joshf’s picture

Status: Needs review » Reviewed & tested by the community

I've tested this in a vanilla D10.5 install and the waitlist features function as expected.

  • pfrenssen committed d03ff275 on 2.0.x authored by muriqui
    [#3542050] feat: Use a boolean for the waitlist state
    
    By: muriqui
    By:...

  • pfrenssen committed d03ff275 on 3.0.x authored by muriqui
    [#3542050] feat: Use a boolean for the waitlist state
    
    By: muriqui
    By:...
pfrenssen’s picture

Thanks a lot for working on this! Merged both in 2.0.x and 3.0.x.

  • pfrenssen committed 8439f5ff on 3.0.x authored by muriqui
    [#3542050] feat: Use a boolean for the waitlist state
    
    By: muriqui
    By:...
pfrenssen’s picture

Status: Reviewed & tested by the community » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.