sleeyax / aternos-api

Unofficial aternos.org API/library to start & stop servers programmatically
GNU General Public License v3.0
19 stars 6 forks source link

Endpoint fixes #7

Closed ganiskowicz closed 1 year ago

ganiskowicz commented 1 year ago

Hey! Sorry for the confusion with my last comment, but I received your email and would be glad to make this pull request. I know very little about the go language (or GitHub for that matter) but I realized that a few endpoints were outdated. Changing the following endpoints fixed the the bug that stopped the server from being start/stoped remotely.

panel/ajax/start.php > ajax/server/start panel/ajax/confirm.php > ajax/server/confirm * panel/ajax/stop.php > ajax/server/stop

*I assume this would be the corresponding endpoint

ganiskowicz commented 1 year ago

The amount of commits was me messing with the repository names (which I reverted). The only changes that apply should only be the new endpoints.

sleeyax commented 1 year ago

I see. So I take it you tested this and is confirmed working right?

ganiskowicz commented 1 year ago

Yes I tested it and confirmed that two of the endpoints start/stop work minus the one denoted with the asterisk. I never dug into the code to find where the confirm endpoint would be used, however nothing broke while using the aternos-discord-bot. I was able to remotely start and stop with no issue.

ganiskowicz commented 1 year ago

I just checked the aternos-discord-bot source and it does use that endpoint so yes, all three endpoints are opperational.

sleeyax commented 1 year ago

Thank you for confirming, usually I test myself but since this is a minor change and I see no reason you'd submit bad code intentionally I'm just gonna merge this :)