[LIB_REFACTOR] Fix requires

This commit is contained in:
Miguel Dantas 2019-08-23 13:36:02 +01:00 committed by Diogo Peralta Cordeiro
parent 2ab2e22a36
commit ab3e8ce21d
105 changed files with 123 additions and 123 deletions

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/togglepeopletag.php';
require_once INSTALLDIR . '/lib/account/togglepeopletag.php';
/**
*

View File

@ -30,7 +30,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/apilistusers.php';
require_once INSTALLDIR . '/lib/api/apilistusers.php';
class ApiListMembersAction extends ApiListUsersAction
{

View File

@ -29,7 +29,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/apilistusers.php';
require_once INSTALLDIR . '/lib/api/apilistusers.php';
class ApiListSubscribersAction extends ApiListUsersAction
{

View File

@ -35,7 +35,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/atomlistnoticefeed.php';
require_once INSTALLDIR . '/lib/feeds/atomlistnoticefeed.php';
/**
* Returns the most recent notices (default 20) posted to the list specified by ID

View File

@ -32,8 +32,8 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/profilelist.php';
require_once INSTALLDIR . '/lib/publicgroupnav.php';
require_once INSTALLDIR . '/lib/profile/profilelist.php';
require_once INSTALLDIR . '/lib/groups/publicgroupnav.php';
/**
* List of featured users

View File

@ -31,8 +31,8 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once(INSTALLDIR . '/lib/profilelist.php');
require_once INSTALLDIR . '/lib/publicgroupnav.php';
require_once INSTALLDIR . '/lib/profile/profilelist.php';
require_once INSTALLDIR . '/lib/groups/publicgroupnav.php';
/**
* List of group members

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/grouplist.php';
require_once INSTALLDIR . '/lib/groups/grouplist.php';
/**
* Latest groups

View File

@ -32,8 +32,8 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
//require_once INSTALLDIR.'/lib/searchaction.php';
//require_once INSTALLDIR.'/lib/profilelist.php';
require_once INSTALLDIR . '/lib/search/searchaction.php';
require_once INSTALLDIR . '/lib/profile/profilelist.php';
/**
* Group search action class.

View File

@ -33,7 +33,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/searchaction.php';
require_once INSTALLDIR . '/lib/search/searchaction.php';
/**
* Notice search action class.

View File

@ -33,7 +33,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/mail.php';
require_once INSTALLDIR . '/lib/util/mail.php';
/**
* Nudge a user action class.

View File

@ -32,8 +32,8 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/searchaction.php';
require_once INSTALLDIR . '/lib/profilelist.php';
require_once INSTALLDIR . '/lib/search/searchaction.php';
require_once INSTALLDIR . '/lib/profile/profilelist.php';
/**
* People search action class.

View File

@ -35,7 +35,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/peopletaglist.php';
require_once INSTALLDIR . '/lib/profile/peopletaglist.php';
// cache 3 pages
define('PEOPLETAG_CACHE_WINDOW', PEOPLETAGS_PER_PAGE*3 + 1);

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once(INSTALLDIR . '/lib/profilelist.php');
require_once INSTALLDIR . '/lib/profile/profilelist.php';
/**
* List of people tagged by the user with a tag

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/peopletaglist.php';
require_once INSTALLDIR . '/lib/profile/peopletaglist.php';
class PeopletagsbyuserAction extends Action
{

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/peopletaglist.php';
require_once INSTALLDIR . '/lib/profile/peopletaglist.php';
class PeopletagsforuserAction extends Action
{

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once(INSTALLDIR . '/lib/profilelist.php');
require_once INSTALLDIR . '/lib/profile/profilelist.php';
/**
* List of peopletag subscribers

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/peopletaglist.php';
require_once INSTALLDIR . '/lib/profile/peopletaglist.php';
class PeopletagsubscriptionsAction extends Action
{

View File

@ -16,7 +16,7 @@
defined('STATUSNET') || die();
require_once INSTALLDIR . '/lib/deletetree.php';
require_once INSTALLDIR . '/lib/util/deletetree.php';
/**
* Form for deleting a plugin

View File

@ -16,7 +16,7 @@
defined('STATUSNET') || die();
require_once INSTALLDIR . '/lib/deletetree.php';
require_once INSTALLDIR . '/lib/util/deletetree.php';
/**
* Plugin install action.

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/peopletageditform.php';
require_once INSTALLDIR . '/lib/profile/peopletageditform.php';
/**
* Subscription action

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/togglepeopletag.php';
require_once INSTALLDIR . '/lib/account/togglepeopletag.php';
/**
* Subscription action

View File

@ -31,7 +31,7 @@ if (!defined('GNUSOCIAL')) {
exit(1);
}
require_once INSTALLDIR . '/lib/noticelist.php';
require_once INSTALLDIR . '/lib/notices/noticelist.php';
/**
* Show a single notice

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/grouplist.php';
require_once INSTALLDIR . '/lib/groups/grouplist.php';
/**
* User groups page

View File

@ -142,7 +142,7 @@ class Confirm_address extends Managed_DataObject
$args['sitename'],
$args['url']);
require_once(INSTALLDIR . '/lib/mail.php');
require_once INSTALLDIR . '/lib/util/mail.php';
return mail_to_user($this->getProfile()->getUser(), $subject, $body, $args['headers'], $this->getAddress());
}

View File

@ -573,7 +573,7 @@ class Memcached_DataObject extends Safe_DataObject
function getSearchEngine($table)
{
require_once INSTALLDIR . '/lib/search_engines.php';
require_once INSTALLDIR . '/lib/search/search_engines.php';
if (Event::handle('GetSearchEngine', array($this, $table, &$search_engine))) {
if ('mysql' === common_config('db', 'type')) {

View File

@ -1890,7 +1890,7 @@ class Notice extends Managed_DataObject
$recipientIds = $this->getReplies();
if (Event::handle('StartNotifyMentioned', array($this, &$recipientIds))) {
require_once INSTALLDIR . '/lib/mail.php';
require_once INSTALLDIR . '/lib/util/mail.php';
foreach ($recipientIds as $recipientId) {
try {

View File

@ -872,7 +872,7 @@ class User extends Managed_DataObject
static function recoverPassword($nore)
{
require_once(INSTALLDIR . '/lib/mail.php');
require_once INSTALLDIR . '/lib/util/mail.php';
// $confirm_email will be used as a fallback if our user doesn't have a confirmed email
$confirm_email = null;

View File

@ -32,7 +32,7 @@ if (!defined('GNUSOCIAL')) {
exit(1);
}
require_once(INSTALLDIR . '/lib/activitystreamjsondocument.php');
require_once INSTALLDIR . '/lib/activitystreams/activitystreamjsondocument.php';
/**
* A noun-ish thing in the activity universe

View File

@ -359,7 +359,7 @@ class UserActivityStream extends AtomUserNoticeFeed
function writeJSON($handle)
{
require_once INSTALLDIR . '/lib/activitystreamjsondocument.php';
require_once INSTALLDIR . '/lib/activitystreams/activitystreamjsondocument.php';
fwrite($handle, '{"items": [');
$this->renderEntries(Feed::JSON, $handle);
fwrite($handle, ']}');

View File

@ -16,7 +16,7 @@
defined('STATUSNET') || die();
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for enabling a plugin

View File

@ -16,8 +16,8 @@
defined('STATUSNET') || die();
require INSTALLDIR . "/lib/pluginenableform.php";
require INSTALLDIR . "/lib/plugindisableform.php";
require INSTALLDIR . "/lib/admin/pluginenableform.php";
require INSTALLDIR . "/lib/admin/plugindisableform.php";
/**
* Plugin list

View File

@ -30,7 +30,7 @@
if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/apiaction.php';
require_once INSTALLDIR . '/lib/api/apiaction.php';
/**
* Base action for API OAuth enpoints. Clean up the

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for editing an application

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/servererroraction.php';
require_once INSTALLDIR . '/lib/action/servererroraction.php';
/**
* Class for displaying DB Errors

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for leaving a group

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for editing a group

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/widget.php';
require_once INSTALLDIR . '/lib/ui/widget.php';
/**
* Widget to show a list of groups

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/grouplist.php';
require_once INSTALLDIR . '/lib/groups/grouplist.php';
/**
* Widget to show a list of groups, good for sidebar

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/noticelist.php';
require_once INSTALLDIR . '/lib/notices/noticelist.php';
/**
* StatusNet, the distributed open-source microblogging tool

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for unsubscribing from a user

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/widget.php';
require_once INSTALLDIR . '/lib/ui/widget.php';
/**
* Menu for login group of actions

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for nudging a user

View File

@ -30,8 +30,8 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/togglepeopletag.php';
require_once INSTALLDIR . '/lib/util/form.php';
require_once INSTALLDIR . '/lib/account/togglepeopletag.php';
/**
* Form for editing a peopletag

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/widget.php';
require_once INSTALLDIR . '/lib/ui/widget.php';
/**
* Base class for all actions

View File

@ -30,7 +30,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/widget.php';
require_once INSTALLDIR . '/lib/ui/widget.php';
/**
* Tabset for a group

View File

@ -30,7 +30,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/peopletaglist.php';
require_once INSTALLDIR . '/lib/profile/peopletaglist.php';
define('PEOPLETAGS_PER_SECTION', 6);

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for subscribing to a user

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for subscribing to a peopletag

View File

@ -30,7 +30,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for editing a peopletag

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for unsubscribing from a user

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for unsubscribing to a peopletag

View File

@ -36,7 +36,7 @@ class PingQueueHandler extends QueueHandler {
return true;
}
require_once INSTALLDIR . '/lib/ping.php';
require_once INSTALLDIR . '/lib/util/ping.php';
return ping_broadcast_notice($notice);
}
}

View File

@ -36,7 +36,7 @@ class SmsQueueHandler extends QueueHandler
return true;
}
require_once(INSTALLDIR . '/lib/mail.php');
require_once INSTALLDIR . '/lib/util/mail.php';
return mail_broadcast_notice_sms($notice);
}
}

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/searchgroupnav.php';
require_once INSTALLDIR . '/lib/search/searchgroupnav.php';
/**
* Base search action class.

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for inviting collegues and friends

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/widget.php';
require_once INSTALLDIR . '/lib/ui/widget.php';
/**
* Local nav menu for subscriptions, subscribers

View File

@ -19,7 +19,7 @@
if (!defined('GNUSOCIAL')) { exit(1); }
require_once(INSTALLDIR . '/lib/util/channel.php');
require_once(INSTALLDIR . '/lib/ui/channel.php');
class Command
{

View File

@ -19,7 +19,7 @@
if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); }
require_once INSTALLDIR . '/lib/command.php';
require_once INSTALLDIR . '/lib/util/command.php';
class CommandInterpreter
{

View File

@ -24,7 +24,7 @@ mb_internal_encoding('UTF-8');
// All the fun stuff to actually initialize GNU social's framework code,
// without loading up a site configuration.
require_once INSTALLDIR . '/lib/framework.php';
require_once INSTALLDIR . '/lib/util/framework.php';
try {
GNUsocial::init(@$server, @$path, @$conffile);

View File

@ -32,7 +32,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
require_once INSTALLDIR . '/lib/widget.php';
require_once INSTALLDIR . '/lib/ui/widget.php';
/**
* Base class for forms

View File

@ -100,12 +100,12 @@ require_once 'DB/DataObject/Cast.php'; # for dates
global $_DB;
$_DB = new DB;
require_once INSTALLDIR . '/lib/language.php';
require_once INSTALLDIR . '/lib/util/language.php';
// This gets included before the config file, so that admin code and plugins
// can use it
require_once INSTALLDIR . '/lib/event.php';
require_once INSTALLDIR . '/lib/util/event.php';
require_once INSTALLDIR . '/lib/modules/Module.php';
require_once INSTALLDIR . '/lib/modules/Plugin.php';
@ -163,9 +163,9 @@ spl_autoload_register(function ($class) {
return;
}
});
require_once INSTALLDIR . '/lib/util.php';
require_once INSTALLDIR . '/lib/action.php';
require_once INSTALLDIR . '/lib/mail.php';
require_once INSTALLDIR . '/lib/util/util.php';
require_once INSTALLDIR . '/lib/action/action.php';
require_once INSTALLDIR . '/lib/util/mail.php';
//set PEAR error handling to use regular PHP exceptions
function PEAR_ErrorToPEAR_Exception(PEAR_Error $err)

View File

@ -352,7 +352,7 @@ class GNUsocial
protected static function defaultConfig()
{
global $_server, $_path;
require(INSTALLDIR . '/lib/default.php');
require(INSTALLDIR . '/lib/util/default.php');
return $default;
}

View File

@ -152,11 +152,11 @@ abstract class Installer
if (!$this->skipConfig) {
define('GNUSOCIAL', true);
define('STATUSNET', true);
require_once INSTALLDIR . '/lib/language.php';
require_once INSTALLDIR . '/lib/util/language.php';
$_server = $this->server;
$_path = $this->path; // We won't be using those so it's safe to do this small hack
require_once INSTALLDIR . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'util.php';
require_once INSTALLDIR . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'default.php';
require_once INSTALLDIR . '/lib/util/util.php';
require_once INSTALLDIR . '/lib/util/default.php';
$fileSubdirs = [
empty($this->avatarDir) ? $default['avatar']['dir'] : $this->avatarDir,
empty($this->fileDir) ? $default['attachments']['dir'] : $this->fileDir
@ -535,7 +535,7 @@ abstract class Installer
// initalize hostname from install arguments, so it can be used to find
// the /etc config file from the commandline installer
$server = $this->server;
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/util/common.php';
$data = ['nickname' => $this->adminNick,
'password' => $this->adminPass,
@ -580,7 +580,7 @@ abstract class Installer
define('STATUSNET', true);
}
require_once INSTALLDIR . '/lib/framework.php';
require_once INSTALLDIR . '/lib/util/framework.php';
GNUsocial::initDefaults($this->server, $this->path);
if ($this->siteProfile == "singleuser") {

View File

@ -17,7 +17,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
require_once(INSTALLDIR . '/lib/mail.php');
require_once INSTALLDIR . '/lib/util/mail.php';
require_once('Mail/mimeDecode.php');
// @todo FIXME: we use both Mail_mimeDecode and mailparse

View File

@ -1102,7 +1102,7 @@ function callback_helper($matches, $callback, $arg = null)
return substr($matches[0], 0, $left) . $result . substr($matches[0], $right);
}
require_once INSTALLDIR . "/lib/callableleftcurry.php";
require_once INSTALLDIR . '/lib/util/callableleftcurry.php';
function common_linkify($url)
{

View File

@ -602,7 +602,7 @@ function mail_notify_fave(User $rcpt, Profile $sender, Notice $notice)
}
// We need the global mail.php for various mail related functions below.
require_once INSTALLDIR . '/lib/mail.php';
require_once INSTALLDIR . '/lib/util/mail.php';
$bestname = $sender->getBestName();

View File

@ -34,7 +34,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/noticelist.php';
require_once INSTALLDIR . '/lib/notices/noticelist.php';
/**
* SpamAction

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for disfavoring a notice anonymously

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for favoring a notice anonymously

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for inviting collegues and friends

View File

@ -34,7 +34,7 @@ if (!defined('GNUSOCIAL')) {
if (!defined('STATUSNET')) { // Compatibility
define('STATUSNET', true);
}
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/util/common.php';
final class oEmbedTest extends TestCase
{

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once(__DIR__ . '/lib/util.php');
require_once __DIR__ . '/lib/util/util.php';
define('LINKBACKPLUGIN_VERSION', '0.2');

View File

@ -2,7 +2,7 @@
if (!defined('GNUSOCIAL')) { exit(1); }
require_once __DIR__ . '/lib/util.php';
require_once __DIR__ . '/lib/util/util.php';
/*
* This plugin lets you type @twitter.com/singpolyma

View File

@ -24,7 +24,7 @@
if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); }
require_once INSTALLDIR . '/lib/peopletaglist.php';
require_once INSTALLDIR . '/lib/profile/peopletaglist.php';
/**
* Key UI methods:

View File

@ -9,7 +9,7 @@ define('INSTALLDIR', realpath(dirname(__FILE__) . '/../../..'));
define('GNUSOCIAL', true);
define('STATUSNET', true); // compatibility
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/util/common.php';
require_once INSTALLDIR . '/plugins/OStatus/lib/feeddiscovery.php';
class FeedDiscoveryTest extends PHPUnit_Framework_TestCase

View File

@ -9,7 +9,7 @@ define('INSTALLDIR', realpath(dirname(__FILE__) . '/../../..'));
define('GNUSOCIAL', true);
define('STATUSNET', true); // compatibility
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/util/common.php';
class MagicEnvelopeTest extends PHPUnit_Framework_TestCase
{

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for showing / revising an answer

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for showing a question

View File

@ -31,7 +31,7 @@
if (!defined('GNUSOCIAL')) { exit(1); }
require_once dirname(__DIR__) . '/twitter.php';
require_once INSTALLDIR . '/lib/oauthclient.php';
require_once INSTALLDIR . '/lib/util/oauthclient.php';
/**
* Class for doing OAuth authentication against Twitter

View File

@ -37,8 +37,8 @@ Batch script for retrieving Twitter messages from foreign service.
END_OF_TRIM_HELP;
require_once INSTALLDIR . '/scripts/commandline.inc';
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/daemon.php';
require_once INSTALLDIR . '/lib/util/common.php';
require_once INSTALLDIR . '/lib/util/daemon.php';
require_once dirname(__DIR__) . '/twitter.php';
/**

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for clearing profile flags

View File

@ -31,7 +31,7 @@ if (!defined('STATUSNET')) {
exit(1);
}
require_once INSTALLDIR . '/lib/form.php';
require_once INSTALLDIR . '/lib/util/form.php';
/**
* Form for flagging a profile

View File

@ -168,7 +168,7 @@ if (preg_replace("/\?.+$/", "", $_SERVER['REQUEST_URI']) === preg_replace("/^\/$
die("Fancy URL support detection succeeded. We suggest you enable this to get fancy (pretty) URLs.");
}
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/util/common.php';
/**
* Format a backtrace line for debug output roughly like debug_print_backtrace() does.

View File

@ -120,7 +120,7 @@ foreach ($options as $option) {
}
}
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/util/common.php';
set_error_handler('common_error_handler');

View File

@ -29,7 +29,7 @@ define('PUBLICDIR', INSTALLDIR . DIRECTORY_SEPARATOR . 'public');
define('GNUSOCIAL', true);
define('STATUSNET', true);
require_once INSTALLDIR . '/lib/common.php';
require_once INSTALLDIR . '/lib/util/common.php';
// Try to find an autoloader for a local psysh version.
// We'll wrap this whole mess in a Closure so it doesn't leak any globals.