Browse Source

Move Probe to src

pull/3445/head
Hypolite Petovan 5 years ago
parent
commit
36e515ee6d
  1. 3
      include/Contact.php
  2. 3
      include/Scrape.php
  3. 1
      include/bb2diaspora.php
  4. 2
      include/cronjobs.php
  5. 2
      include/network.php
  6. 1
      include/ostatus.php
  7. 3
      include/salmon.php
  8. 1
      include/socgraph.php
  9. 1
      mod/contacts.php
  10. 2
      mod/dfrn_confirm.php
  11. 2
      mod/dfrn_request.php
  12. 2
      mod/photos.php
  13. 2
      mod/profiles.php
  14. 3
      mod/webfinger.php
  15. 5
      src/Network/Probe.php

3
include/Contact.php

@ -1,6 +1,7 @@
<?php
use Friendica\App;
use Friendica\Network\Probe;
// Included here for completeness, but this is a very dangerous operation.
// It is the caller's responsibility to confirm the requestor's intent and
@ -363,7 +364,6 @@ function get_contact_details_by_addr($addr, $uid = -1) {
dbesc($addr));
if (!dbm::is_result($r)) {
require_once('include/Probe.php');
$data = Probe::uri($addr);
$profile = get_contact_details_by_url($data['url'], $uid);
@ -589,7 +589,6 @@ function get_contact($url, $uid = 0, $no_update = false) {
return 0;
}
require_once('include/Probe.php');
$data = Probe::uri($url);
// Last try in gcontact for unsupported networks

3
include/Scrape.php

@ -1,5 +1,6 @@
<?php
require_once('include/Probe.php');
use Friendica\Network\Probe;
/**
*

1
include/bb2diaspora.php

@ -1,6 +1,7 @@
<?php
use Friendica\App;
use Friendica\Network\Probe;
use League\HTMLToMarkdown\HtmlConverter;

2
include/cronjobs.php

@ -2,11 +2,11 @@
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Network\Probe;
function cronjobs_run(&$argv, &$argc){
global $a;
require_once('include/Probe.php');
require_once 'include/datetime.php';
require_once 'include/ostatus.php';
require_once 'include/post_update.php';

2
include/network.php

@ -6,9 +6,9 @@
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Network\Probe;
require_once("include/xml.php");
require_once('include/Probe.php');
/**
* @brief Curl wrapper

1
include/ostatus.php

@ -6,6 +6,7 @@
use Friendica\App;
use Friendica\Core\Config;
require_once("include/Scrape.php");
use Friendica\Network\Probe;
require_once 'include/Contact.php';
require_once 'include/threads.php';

3
include/salmon.php

@ -1,7 +1,8 @@
<?php
use Friendica\Network\Probe;
require_once 'include/crypto.php';
require_once('include/Probe.php');
function get_salmon_key($uri, $keyhash) {
$ret = array();

1
include/socgraph.php

@ -10,6 +10,7 @@
use Friendica\App;
use Friendica\Core\Config;
require_once("include/Scrape.php");
use Friendica\Network\Probe;
require_once 'include/datetime.php';
require_once 'include/network.php';

1
mod/contacts.php

@ -1,6 +1,7 @@
<?php
use Friendica\App;
use Friendica\Network\Probe;
require_once('include/Scrape.php');
require_once 'include/Contact.php';

2
mod/dfrn_confirm.php

@ -19,8 +19,8 @@
*/
use Friendica\App;
use Friendica\Network\Probe;
require_once('include/Probe.php');
require_once 'include/enotify.php';
require_once 'include/group.php';

2
mod/dfrn_request.php

@ -15,7 +15,7 @@
use Friendica\App;
require_once('include/Scrape.php');
require_once('include/Probe.php');
use Friendica\Network\Probe;
require_once 'include/enotify.php';
require_once 'include/group.php';

2
mod/photos.php

@ -2,6 +2,7 @@
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Network\Probe;
require_once 'include/Photo.php';
require_once 'include/photos.php';
@ -12,7 +13,6 @@ require_once 'include/security.php';
require_once 'include/redir.php';
require_once 'include/tags.php';
require_once 'include/threads.php';
require_once 'include/Probe.php';
function photos_init(App $a) {

2
mod/profiles.php

@ -1,9 +1,9 @@
<?php
use Friendica\App;
use Friendica\Network\Probe;
require_once 'include/Contact.php';
require_once('include/Probe.php');
function profiles_init(App $a) {

3
mod/webfinger.php

@ -1,8 +1,7 @@
<?php
use Friendica\App;
require_once("include/Probe.php");
use Friendica\Network\Probe;
function webfinger_content(App $a) {

5
include/Probe.php → src/Network/Probe.php

@ -1,6 +1,9 @@
<?php
namespace Friendica\Network;
/**
* @file include/Probe.php
* @file src/Network/Probe.php
* @brief Functions for probing URL
*
*/
Loading…
Cancel
Save