Selaa lähdekoodia

Allow for the Opcache GUI to be autoloaded via Composer (#23)

* Updated composer.json to allow for autoloading

* Updated class to add namespacing
Jack W-H 8 vuotta sitten
vanhempi
commit
c9664f24db
2 muutettua tiedostoa jossa 7 lisäystä ja 0 poistoa
  1. 5 0
      composer.json
  2. 2 0
      index.php

+ 5 - 0
composer.json

@@ -23,6 +23,11 @@
   "require": {
     "ext-Zend-OPcache": "*",
     "php": ">=5.4"
+  },
+  "autoload": {
+    "psr-4" : {
+      "OpcacheGui\\" : "/"
+    }
   }
 }
 

+ 2 - 0
index.php

@@ -1,5 +1,7 @@
 <?php
 
+namespace OpcacheGui;
+
 /**
  * OPcache GUI
  *