Archived
1
0
Fork 0

Print out the exceptions for Russian games

This commit is contained in:
Alexander Yakovlev 2017-07-13 21:52:30 +07:00
parent 76885ca119
commit 415646165a
3 changed files with 21 additions and 20 deletions

View file

@ -55,4 +55,12 @@ abstract class Source {
curl_close($curl);
return $resp;
}
public function check() {
try {
$this->print();
} catch (Exception $e) {
echo $e->getMessage();
echo $e->getTraceAsString();
}
}
}

View file

@ -14,16 +14,11 @@ if (PHP_SAPI !== 'cli') {
echo '<!DOCTYPE html><html><body><code><pre>';
}
try {
(new Source\Textadventures())->print();
(new Source\IFDB())->print();
(new Source\Dashingdon())->print();
(new Source\Itch())->print();
(new Source\Hyperbook())->print();
} catch (Exception $e) {
echo $e->getMessage();
var_dump($e->getTrace());
}
(new Source\Textadventures())->check();
(new Source\IFDB())->check();
(new Source\Dashingdon())->check();
(new Source\Itch())->check();
(new Source\Hyperbook())->check();
if (PHP_SAPI !== 'cli') {
echo '</pre></code></body></html>';

View file

@ -14,16 +14,14 @@ if (PHP_SAPI !== 'cli') {
echo '<!DOCTYPE html><html><body><code><pre>';
}
try {
//(new Source\Urq())->print();
(new Source\Qsp())->print();
(new Source\Kvester())->print();
(new Source\Apero())->print();
(new Source\Instead())->print();
(new Source\Storymaze())->print();
(new Source\Hyperbook())->print();
(new Source\Questbook())->print();
} catch (Exception $e) {}
(new Source\Urq())->check();
(new Source\Qsp())->check();
(new Source\Kvester())->check();
(new Source\Apero())->check();
(new Source\Instead())->check();
(new Source\Storymaze())->check();
(new Source\Hyperbook())->check();
(new Source\Questbook())->check();
if (PHP_SAPI !== 'cli') {
echo '</pre></code></body></html>';