[ActivityPub] Move models from 'classes' to 'lib/models'

This commit is contained in:
Diogo Cordeiro 2019-08-13 02:54:38 +01:00 committed by Diogo Peralta Cordeiro
parent ec749aa350
commit 3cac110148
14 changed files with 21 additions and 20 deletions

View File

@ -26,13 +26,14 @@
defined('GNUSOCIAL') || die();
// Import required files by the plugin
require_once __DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'httpsignature.php';
require_once __DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'discoveryhints.php';
require_once __DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'explorer.php';
require_once __DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'postman.php';
require_once __DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'inbox_handler.php';
require_once __DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'activitypubqueuehandler.php';
// Import plugin libs
foreach (glob(__DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . '*.php') as $filename) {
require_once $filename;
}
// Import plugin models
foreach (glob(__DIR__ . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'models' . DIRECTORY_SEPARATOR . '*.php') as $filename) {
require_once $filename;
}
// So that this isn't hardcoded everywhere
define('ACTIVITYPUB_BASE_ACTOR_URI', common_root_url().'index.php/user/');

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_accept extends Managed_DataObject
class Activitypub_accept
{
/**
* Generates an ActivityPub representation of a Accept

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_announce extends Managed_DataObject
class Activitypub_announce
{
/**
* Generates an ActivityPub representation of a Announce

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_attachment extends Managed_DataObject
class Activitypub_attachment
{
/**
* Generates a pretty array from an Attachment object

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_create extends Managed_DataObject
class Activitypub_create
{
/**
* Generates an ActivityPub representation of a Create

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_delete extends Managed_DataObject
class Activitypub_delete
{
/**
* Generates an ActivityPub representation of a Delete

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_error extends Managed_DataObject
class Activitypub_error
{
/**
* Generates a pretty error from a string

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_follow extends Managed_DataObject
class Activitypub_follow
{
/**
* Generates an ActivityPub representation of a subscription

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_like extends Managed_DataObject
class Activitypub_like
{
/**
* Generates an ActivityPub representation of a Like

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_mention_tag extends Managed_DataObject
class Activitypub_mention_tag
{
/**
* Generates an ActivityPub representation of a Mention Tag

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_notice extends Managed_DataObject
class Activitypub_notice
{
/**
* Generates a pretty notice from a Notice object

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_reject extends Managed_DataObject
class Activitypub_reject
{
/**
* Generates an ActivityPub representation of a Reject

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_tag extends Managed_DataObject
class Activitypub_tag
{
/**
* Generates a pretty tag from a Tag object

View File

@ -34,7 +34,7 @@ defined('GNUSOCIAL') || die();
* @author Diogo Cordeiro <diogo@fc.up.pt>
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
*/
class Activitypub_undo extends Managed_DataObject
class Activitypub_undo
{
/**
* Generates an ActivityPub representation of a Undo