accept new connection broke yesterday

This commit is contained in:
friendica 2014-02-03 14:03:43 -08:00
parent 6c91580716
commit c4d0884596
4 changed files with 10 additions and 4 deletions

View File

@ -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 );

View File

@ -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

View File

@ -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

View File

@ -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>