unset($db_host, $db_user, $db_pass, $db_data);
}
- $a->start_process();
-
require_once("include/session.php");
require_once("include/datetime.php");
require_once('include/items.php');
} elseif($cmd === 'removeme') {
$r = q("SELECT `contact`.*, `user`.`pubkey` AS `upubkey`, `user`.`prvkey` AS `uprvkey`,
`user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
- `user`.`page-flags`, `user`.`prvnets`, `user`.`guid`
+ `user`.`page-flags`, `user`.`prvnets`, `user`.`account-type`, `user`.`guid`
FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
WHERE `contact`.`uid` = %d AND `contact`.`self` LIMIT 1",
intval($item_id));
$r = q("SELECT `contact`.*, `user`.`pubkey` AS `upubkey`, `user`.`prvkey` AS `uprvkey`,
`user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
- `user`.`page-flags`, `user`.`prvnets`
+ `user`.`page-flags`, `user`.`prvnets`, `user`.`account-type`
FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
WHERE `contact`.`uid` = %d AND `contact`.`self` = 1 LIMIT 1",
intval($uid)
foreach($r as $rr) {
if((! $mail) && (! $fsuggest) && (! $followup)) {
- q("insert into deliverq ( `cmd`,`item`,`contact` ) values ('%s', %d, %d )",
- dbesc($cmd),
- intval($item_id),
- intval($rr['id'])
+ q("INSERT INTO `deliverq` (`cmd`,`item`,`contact`) VALUES ('%s', %d, %d)
+ ON DUPLICATE KEY UPDATE `cmd` = '%s', `item` = %d, `contact` = %d",
+ dbesc($cmd), intval($item_id), intval($rr['id']),
+ dbesc($cmd), intval($item_id), intval($rr['id'])
);
}
}