Compare commits

..

17 Commits

Author SHA1 Message Date
a5fd8adc2f Update plugin.yml 2023-08-26 11:01:28 +07:00
267ea58c8d Update README.md 2023-08-26 11:00:54 +07:00
55e3a9df9e modified: src/Matthww/PlayerInfo/Tasks/FetchModelsTask.php 2023-08-15 20:30:15 +07:00
94cab0f223 modified: src/Matthww/PlayerInfo/Tasks/FetchModelsTask.php 2023-08-15 20:29:05 +07:00
8e659424cd modified: src/Matthww/PlayerInfo/Tasks/FetchModelsTask.php 2023-08-15 20:27:34 +07:00
7ac9fd5280 modified: src/Matthww/PlayerInfo/Tasks/FetchModelsTask.php 2023-08-15 20:26:03 +07:00
b805123b10 Update PlayerInfo.php 2023-08-15 20:23:43 +07:00
a3d19b77c8 Create .poggit.yml
Poggit-CI is enabled for this repo by @mukeenanyafiq
Visit the Poggit-CI page for this repo at https://poggit.pmmp.io/ci/mukeenanyafiq/PlayerInfo
2023-08-15 20:22:06 +07:00
4b4e8bcc18 modified: src/Matthww/PlayerInfo/PlayerInfo.php 2023-08-15 06:02:21 +07:00
f86a7c5e44 modified: src/Matthww/PlayerInfo/PlayerInfo.php 2023-08-15 05:47:35 +07:00
2b82d564eb modified: src/Matthww/PlayerInfo/PlayerInfo.php 2023-08-15 05:46:21 +07:00
cc7e6c74af Merge branch 'master' of https://github.com/mukeenanyafiq/PlayerInfo 2023-08-14 19:50:45 +07:00
39bf52ed79 modified: src/Matthww/PlayerInfo/PlayerInfo.php 2023-08-14 19:50:01 +07:00
af1162e256 Update README.md 2023-08-14 19:34:16 +07:00
4c1e026fc9 Update plugin.yml 2023-08-14 19:03:04 +07:00
0c7827e18c modified: src/Matthww/PlayerInfo/Tasks/FetchModelsTask.php 2023-08-14 18:45:06 +07:00
2743b944a6 modified: plugin.yml
modified:   resources/config.yml
	modified:   resources/models.yml
	modified:   src/Matthww/PlayerInfo/PlayerInfo.php
	modified:   src/Matthww/PlayerInfo/Tasks/FetchModelsTask.php
	modified:   src/Matthww/PlayerInfo/Tasks/LoadTask.php
	modified:   src/Matthww/PlayerInfo/Tasks/SaveTask.php
	modified:   src/Matthww/PlayerInfo/Tasks/FetchModelsTask.php
2023-08-14 18:43:14 +07:00

View File

@ -15,13 +15,13 @@ class FetchModelsTask extends AsyncTask {
}
public function onRun(): void {
$result = Internet::getURL("https://raw.githubusercontent.com/Matthww/PlayerInfo/master/resources/models.yml");
if(is_null($result)) {
$result = Internet::getURL("https://raw.githubusercontent.com/Matthww/PlayerInfo/master/resources/models.yml")->getBody();
if(!is_string($result)) {
$this->setResult(false);
return;
}
file_put_contents($this->path. "models.yml", $result->getBody());
file_put_contents($this->path. "models.yml", $result);
$this->setResult(true);
}
}