Esempio n. 1
0
 function unblock($other)
 {
     // Get the block record
     $block = Profile_block::get($this->id, $other->id);
     if (!$block) {
         return false;
     }
     $result = $block->delete();
     if (!$result) {
         common_log_db_error($block, 'DELETE', __FILE__);
         return false;
     }
     return true;
 }
Esempio n. 2
0
 function hasBlocked($other)
 {
     $block = Profile_block::get($this->id, $other->id);
     if (empty($block)) {
         $result = false;
     } else {
         $result = true;
     }
     return $result;
 }