aboutsummaryrefslogtreecommitdiffstats
path: root/include/identity.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-10-18 20:59:00 -0700
committerfriendica <info@friendica.com>2012-10-18 20:59:00 -0700
commit2c3c933ed4cf6846c0240f576082da2deda5a25a (patch)
tree1d58de4e19906f40dcf4f1cef1d3fecddd1c1a70 /include/identity.php
parent0b37d4efd69de4306bb27de8d19090c5f1149abc (diff)
downloadvolse-hubzilla-2c3c933ed4cf6846c0240f576082da2deda5a25a.tar.gz
volse-hubzilla-2c3c933ed4cf6846c0240f576082da2deda5a25a.tar.bz2
volse-hubzilla-2c3c933ed4cf6846c0240f576082da2deda5a25a.zip
get profile edits working
Diffstat (limited to 'include/identity.php')
-rw-r--r--include/identity.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/identity.php b/include/identity.php
index d8eb42ae7..ac033edf4 100644
--- a/include/identity.php
+++ b/include/identity.php
@@ -110,10 +110,11 @@ function create_identity($arr) {
$newuid = $ret['channel']['channel_id'];
- $r = q("insert into xchan ( xchan_hash, xchan_guid, xchan_guid_sig, xchan_photo, xchan_addr, xchan_profile, xchan_name, xchan_network, xchan_photo_date, xchan_name_date ) values ('%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s')",
+ $r = q("insert into xchan ( xchan_hash, xchan_guid, xchan_guid_sig, xchan_pubkey, xchan_photo, xchan_addr, xchan_profile, xchan_name, xchan_network, xchan_photo_date, xchan_name_date ) values ('%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s')",
dbesc($hash),
dbesc($ret['channel']['channel_guid']),
dbesc($sig),
+ dbesc($key['pubkey']),
dbesc($a->get_baseurl() . "/photo/profile/{$newuid}"),
dbesc($ret['channel']['channel_address'] . '@' . $a->get_hostname()),
dbesc(z_root() . '/profile/' . $ret['channel']['channel_address']),
@@ -127,10 +128,11 @@ function create_identity($arr) {
// It's ok for this to fail if it's an imported channel, and therefore the hash is a duplicate
- $r = q("INSERT INTO `profile` ( `aid`, `uid`, `profile_name`, `is_default`, `name`, `photo`, `thumb`)
- VALUES ( %d, %d, '%s', %d, '%s', '%s', '%s') ",
+ $r = q("INSERT INTO `profile` ( `aid`, `uid`, `profile_guid`, `profile_name`, `is_default`, `name`, `photo`, `thumb`)
+ VALUES ( %d, %d, '%s', '%s', %d, '%s', '%s', '%s') ",
intval($ret['channel']['channel_account_id']),
intval($newuid),
+ dbesc(random_string()),
t('default'),
1,
dbesc($ret['channel']['channel_name']),