BaseObject moved to src/Core

BaseObject moved to Friendica\Core namespace. References and function calls updated.
This commit is contained in:
Adam Magness 2017-11-16 13:05:41 -05:00
parent fda48ec431
commit ecd9e3e07e
6 changed files with 76 additions and 58 deletions

47
src/Core/BaseObject.php Normal file
View file

@ -0,0 +1,47 @@
<?php
/**
* @file src/Core/BaseObject.php
*/
namespace Friendica\Core;
if (class_exists('BaseObject')) {
return;
}
require_once 'boot.php';
/**
* Basic object
*
* Contains what is useful to any object
*/
class BaseObject
{
private static $app = null;
/**
* Get the app
*
* Same as get_app from boot.php
*/
public function get_app()
{
if (self::$app) {
return self::$app;
}
self::$app = boot::get_app();
return self::$app;
}
/**
* Set the app
*
* @param object $app App
*/
public static function set_app($app)
{
self::$app = $app;
}
}