aboutsummaryrefslogtreecommitdiffhomepage
path: root/WpfTest/GlobalConfig.php
diff options
context:
space:
mode:
Diffstat (limited to 'WpfTest/GlobalConfig.php')
-rw-r--r--WpfTest/GlobalConfig.php21
1 files changed, 6 insertions, 15 deletions
diff --git a/WpfTest/GlobalConfig.php b/WpfTest/GlobalConfig.php
index 4bbfe68..03cfe6f 100644
--- a/WpfTest/GlobalConfig.php
+++ b/WpfTest/GlobalConfig.php
@@ -1,25 +1,16 @@
<?php
namespace WpfTest;
-class GlobalConfig {
- private static GlobalConfig $instance;
-
- private function __construct() {
-
- }
-
- public static function getInstance() {
- if (!isset(self::$instance)) {
- self::$instance = new self();
- }
- return self::$instance;
- }
-
+class GlobalConfig extends Singleton {
public function getCanonicalHost(): string {
return $_SERVER['HTTP_HOST']; // for now this is fine
}
public function getBasePath(): string {
- return 'http://' . $this->getCanonicalHost(); // fix this?
+ return 'http://' . $this->getCanonicalHost(); // FIXME: don't hardcode http
+ }
+
+ public function shouldReportTraces(): bool {
+ return true; // FIXME: don't hardcode
}
} \ No newline at end of file