diff options
author | friendica <info@friendica.com> | 2014-02-03 14:03:43 -0800 |
---|---|---|
committer | friendica <info@friendica.com> | 2014-02-03 14:03:43 -0800 |
commit | c4d088459634d8148620a27c56ba06b33814668f (patch) | |
tree | bb225ee3b1136f4a178605a66527fb34417f3c43 | |
parent | 6c91580716524e03d68d6d3c95f0fa38b91a1362 (diff) | |
download | volse-hubzilla-c4d088459634d8148620a27c56ba06b33814668f.tar.gz volse-hubzilla-c4d088459634d8148620a27c56ba06b33814668f.tar.bz2 volse-hubzilla-c4d088459634d8148620a27c56ba06b33814668f.zip |
accept new connection broke yesterday
-rwxr-xr-x | boot.php | 1 | ||||
-rw-r--r-- | mod/connections.php | 2 | ||||
-rw-r--r-- | mod/connedit.php | 5 | ||||
-rwxr-xr-x | view/tpl/abook_edit.tpl | 6 |
4 files changed, 10 insertions, 4 deletions
@@ -398,6 +398,7 @@ define ( 'TERM_PCATEGORY', 4 ); define ( 'TERM_FILE', 5 ); define ( 'TERM_SAVEDSEARCH', 6 ); define ( 'TERM_THING', 7 ); +define ( 'TERM_BOOKMARK', 8 ); define ( 'TERM_OBJ_POST', 1 ); define ( 'TERM_OBJ_PHOTO', 2 ); diff --git a/mod/connections.php b/mod/connections.php index 2119c69c7..3da9cec74 100644 --- a/mod/connections.php +++ b/mod/connections.php @@ -74,6 +74,7 @@ function connections_post(&$a) { $abook_flags = $orig_record[0]['abook_flags']; $new_friend = false; + if(($_REQUEST['pending']) && ($abook_flags & ABOOK_FLAG_PENDING)) { $abook_flags = ( $abook_flags ^ ABOOK_FLAG_PENDING ); $new_friend = true; @@ -88,6 +89,7 @@ function connections_post(&$a) { intval($contact_id), intval(local_user()) ); + if($r) info( t('Connection updated.') . EOL); else diff --git a/mod/connedit.php b/mod/connedit.php index b7101fcab..3f507cc3b 100644 --- a/mod/connedit.php +++ b/mod/connedit.php @@ -32,7 +32,7 @@ function connedit_init(&$a) { } function connedit_post(&$a) { - + if(! local_user()) return; @@ -86,6 +86,8 @@ function connedit_post(&$a) { $abook_flags = $orig_record[0]['abook_flags']; $new_friend = false; + + if(($_REQUEST['pending']) && ($abook_flags & ABOOK_FLAG_PENDING)) { $abook_flags = ( $abook_flags ^ ABOOK_FLAG_PENDING ); $new_friend = true; @@ -100,6 +102,7 @@ function connedit_post(&$a) { intval($contact_id), intval(local_user()) ); + if($r) info( t('Connection updated.') . EOL); else diff --git a/view/tpl/abook_edit.tpl b/view/tpl/abook_edit.tpl index 265a1a953..274d0d5de 100755 --- a/view/tpl/abook_edit.tpl +++ b/view/tpl/abook_edit.tpl @@ -30,6 +30,9 @@ {{/if}} +<form id="abook-edit-form" action="connedit/{{$contact_id}}" method="post" > +<input type="hidden" name="contact_id" value="{{$contact_id}}"> +<input id="contact-closeness-mirror" type="hidden" name="closeness" value="{{$close}}" /> {{if $is_pending}} @@ -50,9 +53,6 @@ <h3>{{$permlbl}}</h3> <div id="perm-desc" class="descriptive-text">{{$permnote}}</div> -<form id="abook-edit-form" action="connedit/{{$contact_id}}" method="post" > -<input type="hidden" name="contact_id" value="{{$contact_id}}"> -<input id="contact-closeness-mirror" type="hidden" name="closeness" value="{{$close}}" /> {{* {{if $noperms}} <div id="noperm-msg" class="warning-text">{{$noperms}}</div> |