]> git.mxchange.org Git - friendica.git/commitdiff
Merge pull request #4001 from MrPetovan/bug/3999-fix-password-change
authorMichael Vogel <icarus@dabo.de>
Sun, 3 Dec 2017 13:49:10 +0000 (14:49 +0100)
committerGitHub <noreply@github.com>
Sun, 3 Dec 2017 13:49:10 +0000 (14:49 +0100)
Fix password change

18 files changed:
boot.php
include/acl_selectors.php
include/contact_selectors.php
include/items.php
include/uimport.php
mod/contacts.php
mod/dfrn_request.php
mod/hostxrd.php
mod/notice.php
mod/post.php [deleted file]
mod/xrd.php
src/Worker/Cron.php
src/Worker/Delivery.php
src/Worker/Notifier.php
src/Worker/OnePoll.php
update.php
view/templates/auto_request.tpl
view/templates/dfrn_request.tpl

index 9cdaefb2124f11942dce06d58a137d8706bb6559..04e14ac4d3d297ce9cdd04d4a2ebca27ccd89ea6 100644 (file)
--- a/boot.php
+++ b/boot.php
@@ -254,25 +254,24 @@ define('PROTOCOL_SPLITTED_CONV',   6);
  * @{
  */
 define('NETWORK_DFRN',             'dfrn');    // Friendica, Mistpark, other DFRN implementations
-define('NETWORK_ZOT',              'zot!');    // Zot!
-define('NETWORK_OSTATUS',          'stat');    // status.net, identi.ca, GNU-social, other OStatus implementations
+define('NETWORK_ZOT',              'zot!');    // Zot! - Currently unsupported
+define('NETWORK_OSTATUS',          'stat');    // GNU-social, Pleroma, Mastodon, other OStatus implementations
 define('NETWORK_FEED',             'feed');    // RSS/Atom feeds with no known "post/notify" protocol
 define('NETWORK_DIASPORA',         'dspr');    // Diaspora
 define('NETWORK_MAIL',             'mail');    // IMAP/POP
-define('NETWORK_MAIL2',            'mai2');    // extended IMAP/POP
 define('NETWORK_FACEBOOK',         'face');    // Facebook API
 define('NETWORK_LINKEDIN',         'lnkd');    // LinkedIn
-define('NETWORK_XMPP',             'xmpp');    // XMPP
-define('NETWORK_MYSPACE',          'mysp');    // MySpace
+define('NETWORK_XMPP',             'xmpp');    // XMPP - Currently unsupported
+define('NETWORK_MYSPACE',          'mysp');    // MySpace - Currently unsupported
 define('NETWORK_GPLUS',            'goog');    // Google+
 define('NETWORK_PUMPIO',           'pump');    // pump.io
 define('NETWORK_TWITTER',          'twit');    // Twitter
 define('NETWORK_DIASPORA2',        'dspc');    // Diaspora connector
 define('NETWORK_STATUSNET',        'stac');    // Statusnet connector
-define('NETWORK_APPNET',           'apdn');    // app.net
-define('NETWORK_NEWS',             'nntp');    // Network News Transfer Protocol
-define('NETWORK_ICALENDAR',        'ical');    // iCalendar
-define('NETWORK_PNUT',             'pnut');    // pnut.io
+define('NETWORK_APPNET',           'apdn');    // app.net - Dead protocol
+define('NETWORK_NEWS',             'nntp');    // Network News Transfer Protocol - Currently unsupported
+define('NETWORK_ICALENDAR',        'ical');    // iCalendar - Currently unsupported
+define('NETWORK_PNUT',             'pnut');    // pnut.io - Currently unsupported
 define('NETWORK_PHANTOM',          'unkn');    // Place holder
 /**
  * @}
@@ -290,7 +289,6 @@ $netgroup_ids = array(
        NETWORK_FEED     => (-4),
        NETWORK_DIASPORA => (-5),
        NETWORK_MAIL     => (-6),
-       NETWORK_MAIL2    => (-7),
        NETWORK_FACEBOOK => (-8),
        NETWORK_LINKEDIN => (-9),
        NETWORK_XMPP     => (-10),
index ef75d416f6f43a45eef554f4fba06450444d7b14..5ae30d5633f05cdd0ca6805da2ea222264eb0240 100644 (file)
@@ -498,10 +498,9 @@ function acl_lookup(App $a, $out_type = 'json') {
                                WHERE `uid` = %d AND NOT `self`
                                AND NOT `blocked` AND NOT `pending` AND NOT `archive`
                                AND `success_update` >= `failure_update`
-                               AND `network` IN ('%s','%s','%s') $sql_extra2" ,
+                               AND `network` IN ('%s', '%s') $sql_extra2" ,
                        intval(local_user()),
                        dbesc(NETWORK_DFRN),
-                       dbesc(NETWORK_ZOT),
                        dbesc(NETWORK_DIASPORA)
                );
                $contact_count = (int)$r[0]['c'];
@@ -593,12 +592,11 @@ function acl_lookup(App $a, $out_type = 'json') {
        } elseif ($type == 'm') {
                $r = q("SELECT `id`, `name`, `nick`, `micro`, `network`, `url`, `attag`, `addr` FROM `contact`
                        WHERE `uid` = %d AND NOT `self` AND NOT `blocked` AND NOT `pending` AND NOT `archive`
-                       AND `success_update` >= `failure_update` AND `network` IN ('%s','%s','%s')
+                       AND `success_update` >= `failure_update` AND `network` IN ('%s', '%s')
                        $sql_extra2
                        ORDER BY `name` ASC ",
                        intval(local_user()),
                        dbesc(NETWORK_DFRN),
-                       dbesc(NETWORK_ZOT),
                        dbesc(NETWORK_DIASPORA)
                );
        } elseif ($type == 'a') {
index 1e754ac9f7a2655c53ca62897411de481c33c606..67d05f307bebade9f07a111ae78c3a3b21a9a674 100644 (file)
@@ -85,7 +85,6 @@ function network_to_name($s, $profile = "") {
                NETWORK_LINKEDIN => t('LinkedIn'),
                NETWORK_XMPP     => t('XMPP/IM'),
                NETWORK_MYSPACE  => t('MySpace'),
-               NETWORK_MAIL2    => t('Email'),
                NETWORK_GPLUS    => t('Google+'),
                NETWORK_PUMPIO   => t('pump.io'),
                NETWORK_TWITTER  => t('Twitter'),
index 36a7ac2a8c0bc6765258afa10058706c05c7836e..98149dea591e4fd3011d65718c24aadb6b5d6c1a 100644 (file)
@@ -1678,8 +1678,8 @@ function new_follower($importer, $contact, $datarray, $item, $sharing = false) {
                        dbesc($name),
                        dbesc($nick),
                        dbesc($photo),
-                       dbesc(($sharing) ? NETWORK_ZOT : NETWORK_OSTATUS),
-                       intval(($sharing) ? CONTACT_IS_SHARING : CONTACT_IS_FOLLOWER)
+                       dbesc(NETWORK_OSTATUS),
+                       intval(CONTACT_IS_FOLLOWER)
                );
                $r = q("SELECT `id`, `network` FROM `contact` WHERE `uid` = %d AND `url` = '%s' AND `pending` = 1 LIMIT 1",
                                intval($importer['uid']),
index 4e30eabe39ba37db5315b720ff271f22b8b49393..7effcd62ddd9da5f05f74b81cf95f681e8945a5b 100644 (file)
@@ -198,12 +198,6 @@ function import_account(App $a, $file) {
                                case NETWORK_DIASPORA:
                                        //  send relocate message (below)
                                        break;
-                               case NETWORK_ZOT:
-                                       /// @TODO handle zot network
-                                       break;
-                               case NETWORK_MAIL2:
-                                       /// @TODO ?
-                                       break;
                                case NETWORK_FEED:
                                case NETWORK_MAIL:
                                        // Nothing to do
index 69f1884960145776dae8ef104ce0c2490ef69c0e..9feacaf5e38f2e2044f0fdd3aa06f4ed24f8b510 100644 (file)
@@ -559,7 +559,7 @@ function contacts_content(App $a) {
                }
                $lblsuggest = (($contact['network'] === NETWORK_DFRN) ? t('Suggest friends') : '');
 
-               $poll_enabled = in_array($contact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_FEED, NETWORK_MAIL, NETWORK_MAIL2));
+               $poll_enabled = in_array($contact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_FEED, NETWORK_MAIL));
 
                $nettype = sprintf( t('Network type: %s'),network_to_name($contact['network'], $contact["url"]));
 
@@ -586,7 +586,7 @@ function contacts_content(App $a) {
                                                                        '3' => t('Fetch keywords'),
                                                                        '2' => t('Fetch information and keywords')));
                }
-               if (in_array($contact['network'], array(NETWORK_FEED, NETWORK_MAIL, NETWORK_MAIL2)))
+               if (in_array($contact['network'], array(NETWORK_FEED, NETWORK_MAIL)))
                        $poll_interval = contact_poll_interval($contact['priority'],(! $poll_enabled));
 
                if ($contact['network'] == NETWORK_DFRN)
@@ -994,7 +994,7 @@ function _contact_detail_for_template($rr){
  */
 function contact_actions($contact) {
 
-       $poll_enabled = in_array($contact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_FEED, NETWORK_MAIL, NETWORK_MAIL2));
+       $poll_enabled = in_array($contact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_FEED, NETWORK_MAIL));
        $contact_action = array();
 
        // Provide friend suggestion only for Friendica contacts
index 3c7584318690b8f62d432010221ac9c252a2d961..67395a9fcc714abb740ab9eecf15e1ac5177d278 100644 (file)
@@ -292,15 +292,12 @@ function dfrn_request_post(App $a) {
                 *
                 * Cleanup old introductions that remain blocked.
                 * Also remove the contact record, but only if there is no existing relationship
-                * Do not remove email contacts as these may be awaiting email verification
                 */
 
                $r = q("SELECT `intro`.*, `intro`.`id` AS `iid`, `contact`.`id` AS `cid`, `contact`.`rel`
                        FROM `intro` LEFT JOIN `contact` on `intro`.`contact-id` = `contact`.`id`
                        WHERE `intro`.`blocked` = 1 AND `contact`.`self` = 0
-                       AND `contact`.`network` != '%s'
-                       AND `intro`.`datetime` < UTC_TIMESTAMP() - INTERVAL 30 MINUTE ",
-                       dbesc(NETWORK_MAIL2)
+                       AND `intro`.`datetime` < UTC_TIMESTAMP() - INTERVAL 30 MINUTE "
                );
                if (DBM::is_result($r)) {
                        foreach ($r as $rr) {
@@ -315,32 +312,6 @@ function dfrn_request_post(App $a) {
                        }
                }
 
-               /*
-                *
-                * Cleanup any old email intros - which will have a greater lifetime
-                */
-
-               $r = q("SELECT `intro`.*, `intro`.`id` AS `iid`, `contact`.`id` AS `cid`, `contact`.`rel`
-                       FROM `intro` LEFT JOIN `contact` on `intro`.`contact-id` = `contact`.`id`
-                       WHERE `intro`.`blocked` = 1 AND `contact`.`self` = 0
-                       AND `contact`.`network` = '%s'
-                       AND `intro`.`datetime` < UTC_TIMESTAMP() - INTERVAL 3 DAY ",
-                       dbesc(NETWORK_MAIL2)
-               );
-               if (DBM::is_result($r)) {
-                       foreach ($r as $rr) {
-                               if(! $rr['rel']) {
-                                       q("DELETE FROM `contact` WHERE `id` = %d AND NOT `self`",
-                                               intval($rr['cid'])
-                                       );
-                               }
-                               q("DELETE FROM `intro` WHERE `id` = %d",
-                                       intval($rr['iid'])
-                               );
-                       }
-               }
-
-               $email_follow = (x($_POST,'email_follow') ? intval($_POST['email_follow']) : 0);
                $real_name = (x($_POST,'realname') ? notags(trim($_POST['realname'])) : '');
 
                $url = trim($_POST['dfrn_url']);
@@ -351,125 +322,25 @@ function dfrn_request_post(App $a) {
 
                $hcard = '';
 
-               if($email_follow) {
+               // Detect the network
+               $data = Probe::uri($url);
+               $network = $data["network"];
 
-                       if(! validate_email($url)) {
-                               notice( t('Invalid email address.') . EOL);
-                               return;
-                       }
+               // Canonicalise email-style profile locator
+               $url = Probe::webfingerDfrn($url,$hcard);
 
-                       $addr    = $url;
-                       $name    = ($realname) ? $realname : $addr;
-                       $nick    = substr($addr,0,strpos($addr,'@'));
-                       $url     = 'http://' . substr($addr,strpos($addr,'@') + 1);
-                       $nurl    = normalise_url($host);
-                       $poll    = 'email ' . random_string();
-                       $notify  = 'smtp ' . random_string();
-                       $network = NETWORK_MAIL2;
-                       $rel     = CONTACT_IS_FOLLOWER;
-
-                       $mail_disabled = ((function_exists('imap_open') && (! Config::get('system','imap_disabled'))) ? 0 : 1);
-                       if(Config::get('system','dfrn_only'))
-                               $mail_disabled = 1;
-
-                       if(! $mail_disabled) {
-                               $failed = false;
-                               $r = q("SELECT * FROM `mailacct` WHERE `uid` = %d LIMIT 1",
-                                       intval($uid)
-                               );
+               if (substr($url,0,5) === 'stat:') {
 
-                               if (! DBM::is_result($r)) {
-                                       notice( t('This account has not been configured for email. Request failed.') . EOL);
-                                       return;
-                               }
+                       // Every time we detect the remote subscription we define this as OStatus.
+                       // We do this even if it is not OStatus.
+                       // we only need to pass this through another section of the code.
+                       if ($network != NETWORK_DIASPORA) {
+                               $network = NETWORK_OSTATUS;
                        }
 
-                       $r = q("insert into contact ( uid, created, addr, name, nick, url, nurl, poll, notify, blocked, pending, network, rel )
-                               values( %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d, %d, '%s', %d ) ",
-                               intval($uid),
-                               dbesc(datetime_convert()),
-                               dbesc($addr),
-                               dbesc($name),
-                               dbesc($nick),
-                               dbesc($url),
-                               dbesc($nurl),
-                               dbesc($poll),
-                               dbesc($notify),
-                               intval($blocked),
-                               intval($pending),
-                               dbesc($network),
-                               intval($rel)
-                       );
-
-                       $r = q("SELECT `id`, `network` FROM `contact` WHERE `poll` = '%s' AND `uid` = %d LIMIT 1",
-                               dbesc($poll),
-                               intval($uid)
-                       );
-                       if (DBM::is_result($r)) {
-                               $contact_id = $r[0]['id'];
-
-                               $def_gid = get_default_group($uid, $r[0]["network"]);
-                               if (intval($def_gid))
-                                       group_add_member($uid, '', $contact_id, $def_gid);
-
-                               $photo = avatar_img($addr);
-
-                               $r = q("UPDATE `contact` SET
-                                       `photo` = '%s',
-                                       `thumb` = '%s',
-                                       `micro` = '%s',
-                                       `name-date` = '%s',
-                                       `uri-date` = '%s',
-                                       `avatar-date` = '%s',
-                                       `hidden` = 0,
-                                       WHERE `id` = %d
-                               ",
-                                       dbesc($photos[0]),
-                                       dbesc($photos[1]),
-                                       dbesc($photos[2]),
-                                       dbesc(datetime_convert()),
-                                       dbesc(datetime_convert()),
-                                       dbesc(datetime_convert()),
-                                       intval($contact_id)
-                               );
-                       }
-
-                       // contact is created. Now create an introduction
-
-                       $hash = random_string();
-
-                       $r = q("INSERT INTO `intro` ( `uid`, `contact-id`, knowyou, note, hash, datetime, blocked )
-                               VALUES( %d , %d, %d, '%s', '%s', '%s', %d ) ",
-                               intval($uid),
-                               intval($contact_id),
-                               ((x($_POST,'knowyou') && ($_POST['knowyou'] == 1)) ? 1 : 0),
-                               dbesc(notags(trim($_POST['dfrn-request-message']))),
-                               dbesc($hash),
-                               dbesc(datetime_convert()),
-                               1
-                       );
-
-                       // Next send an email verify form to the requestor.
-
+                       $url = substr($url,5);
                } else {
-                       // Detect the network
-                       $data = Probe::uri($url);
-                       $network = $data["network"];
-
-                       // Canonicalise email-style profile locator
-                       $url = Probe::webfingerDfrn($url,$hcard);
-
-                       if (substr($url,0,5) === 'stat:') {
-
-                               // Every time we detect the remote subscription we define this as OStatus.
-                               // We do this even if it is not OStatus.
-                               // we only need to pass this through another section of the code.
-                               if ($network != NETWORK_DIASPORA)
-                                       $network = NETWORK_OSTATUS;
-
-                               $url = substr($url,5);
-                       } else
-                               $network = NETWORK_DFRN;
+                       $network = NETWORK_DFRN;
                }
 
                logger('dfrn_request: url: ' . $url . ',network=' . $network, LOGGER_DEBUG);
@@ -849,27 +720,6 @@ function dfrn_request_content(App $a) {
 
                $page_desc = t("Please enter your 'Identity Address' from one of the following supported communications networks:");
 
-               // see if we are allowed to have NETWORK_MAIL2 contacts
-
-               $mail_disabled = ((function_exists('imap_open') && (! Config::get('system','imap_disabled'))) ? 0 : 1);
-
-               if (Config::get('system','dfrn_only')) {
-                       $mail_disabled = 1;
-               }
-
-               if (! $mail_disabled) {
-                       $r = q("SELECT * FROM `mailacct` WHERE `uid` = %d LIMIT 1",
-                               intval($a->profile['uid'])
-                       );
-                       if (! DBM::is_result($r)) {
-                               $mail_disabled = 1;
-                       }
-               }
-
-               // "coming soon" is disabled for now
-               //$emailnet = (($mail_disabled) ? '' : t("<strike>Connect as an email follower</strike> \x28Coming soon\x29"));
-               $emailnet = "";
-
                $invite_desc = sprintf(
                        t('If you are not yet a member of the free social web, <a href="%s/siteinfo">follow this link to find a public Friendica site and join us today</a>.'),
                        get_server()
@@ -877,7 +727,7 @@ function dfrn_request_content(App $a) {
 
                $o = replace_macros($tpl,array(
                        '$header' => t('Friend/Connection Request'),
-                       '$desc' => t('Examples: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, testuser@identi.ca'),
+                       '$desc' => t('Examples: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, testuser@gnusocial.de'),
                        '$pls_answer' => t('Please answer the following:'),
                        '$does_know_you' => array('knowyou', sprintf(t('Does %s know you?'),$a->profile['name']), false, '', array(t('No'), t('Yes'))),
                        /*'$does_know' => sprintf( t('Does %s know you?'),$a->profile['name']),
@@ -886,12 +736,11 @@ function dfrn_request_content(App $a) {
                        '$add_note' => t('Add a personal note:'),
                        '$page_desc' => $page_desc,
                        '$friendica' => t('Friendica'),
-                       '$statusnet' => t('StatusNet/Federated Social Web'),
-                       '$diaspora' => t('Diaspora'),
+                       '$statusnet' => t('GNU Social (Pleroma, Mastodon)'),
+                       '$diaspora' => t('Diaspora (Socialhome, Hubzilla)'),
                        '$diasnote' => sprintf (t(' - please do not use this form.  Instead, enter %s into your Diaspora search bar.'),$target_addr),
                        '$your_address' => t('Your Identity Address:'),
                        '$invite_desc' => $invite_desc,
-                       '$emailnet' => $emailnet,
                        '$submit' => t('Submit Request'),
                        '$cancel' => t('Cancel'),
                        '$nickname' => $a->argv[1],
index f31497557d7bd98503ec166c3def6bbf2216ff89..0403945efcc0ed7b422889d2426fc4eaf9209f4c 100644 (file)
@@ -18,15 +18,11 @@ function hostxrd_init(App $a) {
                Config::set('system','site_pubkey', $res['pubkey']);
        }
 
-       //$tpl = file_get_contents('view/xrd_host.tpl');
-       /*echo str_replace(array(
-               '$zhost','$zroot','$domain','$zot_post','$bigkey'),array($a->get_hostname(),System::baseUrl(),System::baseUrl(),System::baseUrl() . '/post', salmon_key(Config::get('system','site_pubkey'))),$tpl);*/
        $tpl = get_markup_template('xrd_host.tpl');
        echo replace_macros($tpl, array(
                '$zhost' => $a->get_hostname(),
                '$zroot' => System::baseUrl(),
                '$domain' => System::baseUrl(),
-               '$zot_post' => System::baseUrl() . '/post',
                '$bigkey' => salmon_key(Config::get('system','site_pubkey')),
        ));
        exit();
index 54618bdf8f1776d9af5c4650b5ef740985ce3554..95d16f2dd2ca495c341466d672743d7cda436429 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-/* identi.ca -> friendica items permanent-url compatibility */
+/* GNU Social -> friendica items permanent-url compatibility */
 
 use Friendica\App;
 use Friendica\Core\System;
diff --git a/mod/post.php b/mod/post.php
deleted file mode 100644 (file)
index 58d7695..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-<?php
-/**
- * @file mod/post.php
- * @brief Zot endpoint
- */
-
-use Friendica\App;
-use Friendica\Database\DBM;
-use dba;
-
-require_once 'include/crypto.php';
-// not yet ready for prime time
-//require_once('include/zot.php');
-
-/**
- * @param object $a App
- * @return void
- */
-function post_post(App $a)
-{
-       $bulk_delivery = false;
-
-       if ($a->argc == 1) {
-               $bulk_delivery = true;
-       } else {
-               $nickname = $a->argv[2];
-               $r = dba::select('user', array(), array('nickname' => $nickname, 'account_expired' => 0, 'account_removed' => 0), array('limit' => 1));
-               if (! DBM::is_result($r)) {
-                       http_status_exit(500);
-               }
-
-               $importer = $r;
-       }
-
-       $xml = file_get_contents('php://input');
-
-       logger('mod-post: new zot: ' . $xml, LOGGER_DATA);
-
-       if (! $xml) {
-               http_status_exit(500);
-       }
-
-       $msg = zot_decode($importer, $xml);
-
-       logger('mod-post: decoded msg: ' . print_r($msg, true), LOGGER_DATA);
-
-       if (! is_array($msg)) {
-               http_status_exit(500);
-       }
-
-       $ret = 0;
-       $ret = zot_incoming($bulk_delivery, $importer, $msg);
-       http_status_exit(($ret) ? $ret : 200);
-       // NOTREACHED
-}
index 9f88d85eafacd26b0f0336ad750eb647c287b4e3..49fdde25448a215881883802971c00d64dc529ca 100644 (file)
@@ -94,7 +94,6 @@ function xrd_xml($a, $uri, $alias, $profile_url, $r) {
                '$profile_url' => $profile_url,
                '$hcard_url'   => System::baseUrl() . '/hcard/'         . $r['nickname'],
                '$atom'        => System::baseUrl() . '/dfrn_poll/'     . $r['nickname'],
-               '$zot_post'    => System::baseUrl() . '/post/'          . $r['nickname'],
                '$poco_url'    => System::baseUrl() . '/poco/'          . $r['nickname'],
                '$photo'       => System::baseUrl() . '/photo/profile/' . $r['uid']      . '.jpg',
                '$baseurl' => System::baseUrl(),
index a5ae466ce3404fae26caa7f661e517a22b675467..dd4ca4da2a28a067b07f026dc2a63738717c813e 100644 (file)
@@ -156,18 +156,16 @@ Class Cron {
                $contacts = q("SELECT `contact`.`id` FROM `user`
                                STRAIGHT_JOIN `contact`
                                ON `contact`.`uid` = `user`.`uid` AND `contact`.`rel` IN (%d, %d) AND `contact`.`poll` != ''
-                                       AND `contact`.`network` IN ('%s', '%s', '%s', '%s', '%s', '%s') $sql_extra
+                                       AND `contact`.`network` IN ('%s', '%s', '%s', '%s') $sql_extra
                                        AND NOT `contact`.`self` AND NOT `contact`.`blocked` AND NOT `contact`.`readonly`
                                        AND NOT `contact`.`archive`
                                WHERE NOT `user`.`account_expired` AND NOT `user`.`account_removed` $abandon_sql ORDER BY RAND()",
                        intval(CONTACT_IS_SHARING),
                        intval(CONTACT_IS_FRIEND),
                        dbesc(NETWORK_DFRN),
-                       dbesc(NETWORK_ZOT),
                        dbesc(NETWORK_OSTATUS),
                        dbesc(NETWORK_FEED),
-                       dbesc(NETWORK_MAIL),
-                       dbesc(NETWORK_MAIL2)
+                       dbesc(NETWORK_MAIL)
                );
 
                if (!DBM::is_result($contacts)) {
@@ -192,11 +190,11 @@ Class Cron {
                                        $contact['last-update'] = NULL_DATE;
                                }
 
-                               if (in_array($contact['network'], array(NETWORK_DFRN, NETWORK_ZOT, NETWORK_OSTATUS))) {
+                               if (in_array($contact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS))) {
                                        $contact['priority'] = 2;
                                }
 
-                               if ($contact['subhub'] && in_array($contact['network'], array(NETWORK_DFRN, NETWORK_ZOT, NETWORK_OSTATUS))) {
+                               if ($contact['subhub'] && in_array($contact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS))) {
                                        /*
                                         * We should be getting everything via a hub. But just to be sure, let's check once a day.
                                         * (You can make this more or less frequent if desired by setting 'pushpoll_frequency' appropriately)
index f17aa5507b8dc1843fe823b53f298f9123728903..bb30fc3bf4bef41f477563ea661eeaef735fd48c 100644 (file)
@@ -376,7 +376,6 @@ class Delivery {
                                break;
 
                        case NETWORK_MAIL:
-                       case NETWORK_MAIL2:
 
                                if (Config::get('system','dfrn_only')) {
                                        break;
index 4404b879b7fb04bc6cef55be0979c8fa527becd1..a3a03055ec9f13040bc289652f5eb4e99cd3a923 100644 (file)
@@ -447,7 +447,7 @@ class Notifier {
                                // It only makes sense to distribute answers to OStatus messages to Friendica and OStatus - but not Diaspora
                                $sql_extra = " AND `network` IN ('".NETWORK_OSTATUS."', '".NETWORK_DFRN."')";
                        } else {
-                               $sql_extra = " AND `network` IN ('".NETWORK_OSTATUS."', '".NETWORK_DFRN."', '".NETWORK_DIASPORA."', '".NETWORK_MAIL."', '".NETWORK_MAIL2."')";
+                               $sql_extra = " AND `network` IN ('".NETWORK_OSTATUS."', '".NETWORK_DFRN."', '".NETWORK_DIASPORA."', '".NETWORK_MAIL."')";
                        }
                } else {
                        $public_message = false;
@@ -537,9 +537,8 @@ class Notifier {
                        }
 
                        $r2 = q("SELECT `id`, `name`,`network` FROM `contact`
-                               WHERE `network` in ('%s', '%s') AND `uid` = %d AND NOT `blocked` AND NOT `pending` AND NOT `archive` AND `rel` != %d",
+                               WHERE `network` in ('%s') AND `uid` = %d AND NOT `blocked` AND NOT `pending` AND NOT `archive` AND `rel` != %d",
                                dbesc(NETWORK_DFRN),
-                               dbesc(NETWORK_MAIL2),
                                intval($owner['uid']),
                                intval(CONTACT_IS_SHARING)
                        );
index f7f7bcccf850d0effe6c5f90a118b0f3c6aaccd4..439997be6f0defa19dc1c993717198b9b4f0627f 100644 (file)
@@ -311,7 +311,7 @@ Class OnePoll
                        $xml = $ret['body'];
 
                        unlink($cookiejar);
-               } elseif ($contact['network'] === NETWORK_MAIL || $contact['network'] === NETWORK_MAIL2) {
+               } elseif ($contact['network'] === NETWORK_MAIL) {
 
                        logger("Mail: Fetching for ".$contact['addr'], LOGGER_DEBUG);
 
index ba0867d3a8ca3cfd7c423c25c4486b2df41ecbcd..326c08414e48b766b9c78501287d2cae1842e286 100644 (file)
@@ -1472,9 +1472,6 @@ function update_1164() {
        $r = q("UPDATE `item` SET `network`='%s' WHERE `contact-id` IN (SELECT `id` FROM`contact` WHERE `network` = '%s' AND `contact`.`uid` = `item`.`uid`)",
                NETWORK_DFRN, NETWORK_DFRN);
 
-       $r = q("UPDATE `item` SET `network`='%s' WHERE `contact-id` IN (SELECT `id` FROM`contact` WHERE `network` = '%s' AND `contact`.`uid` = `item`.`uid`)",
-               NETWORK_ZOT, NETWORK_ZOT);
-
        $r = q("UPDATE `item` SET `network`='%s' WHERE `contact-id` IN (SELECT `id` FROM`contact` WHERE `network` = '%s' AND `contact`.`uid` = `item`.`uid`)",
                NETWORK_OSTATUS, NETWORK_OSTATUS);
 
@@ -1487,9 +1484,6 @@ function update_1164() {
        $r = q("UPDATE `item` SET `network`='%s' WHERE `contact-id` IN (SELECT `id` FROM`contact` WHERE `network` = '%s' AND `contact`.`uid` = `item`.`uid`)",
                NETWORK_MAIL, NETWORK_MAIL);
 
-       $r = q("UPDATE `item` SET `network`='%s' WHERE `contact-id` IN (SELECT `id` FROM`contact` WHERE `network` = '%s' AND `contact`.`uid` = `item`.`uid`)",
-               NETWORK_MAIL2, NETWORK_MAIL2);
-
        $r = q("UPDATE `item` SET `network`='%s' WHERE `contact-id` IN (SELECT `id` FROM`contact` WHERE `network` = '%s' AND `contact`.`uid` = `item`.`uid`)",
                NETWORK_FACEBOOK, NETWORK_FACEBOOK);
 
index d6abde0306627874e9a75151c711b2dda87d517c..c7e10482ef0875e942c50ce9a5b51eaf135aca2f 100644 (file)
@@ -4,10 +4,9 @@
 <p id="dfrn-request-intro">
 {{$page_desc}}<br />
 <ul id="dfrn-request-networks">
-<li><a href="http://friendica.com" title="{{$friendica}}">{{$friendica}}</a></li>
-<li><a href="http://joindiaspora.com" title="{{$diaspora}}">{{$diaspora}}</a> {{$diasnote}}</li>
-<li><a href="http://ostatus.org" title="{{$public_net}}" >{{$statusnet}}</a></li>
-{{if $emailnet}}<li>{{$emailnet}}</li>{{/if}}
+<li><a href="http://friendi.ca" title="{{$friendica}}">{{$friendica}}</a></li>
+<li><a href="https://diasporafoundation.org" title="{{$diaspora}}">{{$diaspora}}</a> {{$diasnote}}</li>
+<li><a href="https://gnu.io/social/" title="{{$statusnet}}" >{{$statusnet}}</a></li>
 </ul>
 </p>
 <p>
index 5225bd60b22743f45b88c26c4be0601ac0608882..8e686c33dc1642df69898dc0ba7cfc3cbe6aa0aa 100644 (file)
@@ -5,10 +5,9 @@
 <p id="dfrn-request-intro">
 {{$page_desc}}<br />
 <ul id="dfrn-request-networks">
-<li><a href="http://friendica.com" title="{{$friendica}}">{{$friendica}}</a></li>
-<li><a href="http://joindiaspora.com" title="{{$diaspora}}">{{$diaspora}}</a> {{$diasnote}}</li>
-<li><a href="http://ostatus.org" title="{{$public_net}}" >{{$statusnet}}</a></li>
-{{if $emailnet}}<li>{{$emailnet}}</li>{{/if}}
+<li><a href="http://friendi.ca" title="{{$friendica}}">{{$friendica}}</a></li>
+<li><a href="https://diasporafoundation.org" title="{{$diaspora}}">{{$diaspora}}</a> {{$diasnote}}</li>
+<li><a href="https://gnu.io/social/" title="{{$statusnet}}" >{{$statusnet}}</a></li>
 </ul>
 {{$invite_desc}}
 </p>