Friendica Communications Platform (please note that this is a clone of the repository at github, issues are handled there) https://friendi.ca
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

37 lines
473B

  1. <?php
  2. if(class_exists('BaseObject'))
  3. return;
  4. require_once('boot.php');
  5. /**
  6. * Basic object
  7. *
  8. * Contains what is usefull to any object
  9. */
  10. class BaseObject {
  11. private static $app = null;
  12. /**
  13. * Get the app
  14. *
  15. * Same as get_app from boot.php
  16. */
  17. public function get_app() {
  18. if(self::$app)
  19. return self::$app;
  20. self::$app = get_app();
  21. return self::$app;
  22. }
  23. /**
  24. * Set the app
  25. */
  26. public static function set_app($app) {
  27. self::$app = $app;
  28. }
  29. }
  30. ?>