buddyboss-platform icon indicating copy to clipboard operation
buddyboss-platform copied to clipboard

#1485 - Invalid activation key

Open uday-kokitkar opened this issue 4 years ago • 1 comments

If the user_status is already set to 0, $wpdb->query returns 0. Checking the result with boolean false fixes the issue.

All Submissions:

Changes proposed in this Pull Request:

Fixes #1485 This case is always not reproducible. Sometimes user_status is set to zero before activating the key. Checking wpdb query result strictly helps to fix the false positives.

How to test the changes in this Pull Request:

  1. Register a new user.
  2. Change the user status to 0 in usermeta table.
  3. Try activating the key.

Proof Screenshots or Video

Other information:

  • [x] Have you added an explanation of what your changes do and why you'd like us to include them?
  • [ ] Have you written new tests for your changes, as applicable?
  • [x] Have you successfully run tests with your changes locally?

Changelog entry

Enter a summary of all changes on this Pull Request. This will appear in the changelog if accepted.

uday-kokitkar avatar Apr 14 '21 10:04 uday-kokitkar

Thanks for your pull request. It looks like this may be your first contribution to the BuddyBoss Platform open source project. Please note that this project and all contributions to it are public and bounded by the GPL v2.0 license, and that a record of the contribution (including all personal information you submit with it, including your full name and email address) is maintained indefinitely and may be redistributed with this project. If you are not okay with these terms, please close this pull request. Alternatively, you can let us know about your concerns by adding a comment to this pull request.

welcome[bot] avatar Apr 14 '21 10:04 welcome[bot]