Differences From
Artifact [efbc5e4a8e]:
451 451 end
452 452
453 453 msg = 'profile changes saved'
454 454 --user_refresh = true -- not really necessary here, actually
455 455
456 456 elseif path(1):cmp('sec') then
457 457 credsec_for_uid(co, co.who.id)
458 + elseif path(1):cmp('avi') then
459 + var act = co:ppostv('act')
460 + if act:ref() and act:cmp('clear') then
461 + co.who.avatarid = 0
462 + co.who.source:actor_save(co.who)
463 + msg = 'avatar reset to default'
464 + else goto badop end
458 465 elseif path(1):cmp('users') then
459 466 if path.ct >= 3 then
460 467 var userid, ok = lib.math.shorthand.parse(path(2).ptr, path(2).ct)
461 468 if ok then
462 469 var usr = co.srv:actor_fetch_uid(userid)
463 470 if usr:ref() then --defer usr:free()
464 471 if not co.who:overpowers(usr.ptr) then