Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed [FragLand#216](FragLand#216) for javascript, PHP and Python #217

Merged
merged 9 commits into from
Mar 30, 2024
Merged

fixed [FragLand#216](FragLand#216) for javascript, PHP and Python #217

merged 9 commits into from
Mar 30, 2024

Conversation

molanp
Copy link

@molanp molanp commented Mar 16, 2024

fixed FragLand#216 for javascript, PHP and Python

@AppVeyorBot
Copy link

Build minestat 1.0.0.414 completed (commit 93a055b9c5 by @)

@ldilley ldilley added bug Something isn't working lang: JavaScript Affects the JavaScript version of minestat lang: PHP Affects the PHP version of minestat lang: Python Affects the Python version of minestat labels Mar 21, 2024
@AppVeyorBot
Copy link

@AppVeyorBot
Copy link

@ldilley ldilley self-requested a review March 21, 2024 03:38
Copy link
Member

@ldilley ldilley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Greetings, @molanp.

In reference to issue #216, only data returned from SLP 1.7 JSON queries is potentially impacted, correct? If this is the case, then the JavaScript changes in this PR are unnecessary considering that the JavaScript implementation only supports SLP 1.4/1.5. Furthermore, the included PHP modifications would not correct the issue for SLP 1.7. The changes would need to be made to the following lines (613 and 614) in minestat.php:

      $this->current_players = (int)@$json_data['players']['online'];
      $this->max_players = (int)@$json_data['players']['max'];

Tagging @mindsolve to see if he has any input for the proposed Python changes.

Copy link
Collaborator

@mindsolve mindsolve left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the ping, ldilley :)

I just have one small comment for the python edition.
Thank you, @molanp for the contribution!

Python/minestat/__init__.py Outdated Show resolved Hide resolved
Modify 613 and 614 in PHP.
Handle player_max values correctly.
@molanp
Copy link
Author

molanp commented Mar 29, 2024

Done.

@AppVeyorBot
Copy link

Build minestat 1.0.0.432 completed (commit 985a48c475 by @)

Copy link
Collaborator

@mindsolve mindsolve left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In regards to the Python parts: Approved, thanks for the addition!

@AppVeyorBot
Copy link

@AppVeyorBot
Copy link

@AppVeyorBot
Copy link

Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

Copy link
Member

@ldilley ldilley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The JavaScript and PHP changes now look good as well. Thank you for the fixes, @molanp!

@ldilley ldilley merged commit 0b1ad3a into FragLand:master Mar 30, 2024
10 checks passed
@ldilley ldilley mentioned this pull request Mar 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working lang: JavaScript Affects the JavaScript version of minestat lang: PHP Affects the PHP version of minestat lang: Python Affects the Python version of minestat
Projects
Status: Complete
Development

Successfully merging this pull request may close these issues.

4 participants