streams/Code/Module/Randprof.php

21 lines
340 B
PHP
Raw Normal View History

2016-04-19 03:38:38 +00:00
<?php
2022-02-16 04:08:28 +00:00
namespace Code\Module;
2016-04-19 03:38:38 +00:00
2022-02-16 04:08:28 +00:00
use Code\Web\Controller;
2021-12-02 22:33:36 +00:00
2021-12-02 23:02:31 +00:00
class Randprof extends Controller
{
public function init()
{
$x = random_profile();
2021-12-03 03:01:39 +00:00
if ($x) {
2021-12-02 23:02:31 +00:00
goaway(chanlink_hash($x));
2021-12-03 03:01:39 +00:00
}
2021-12-02 23:02:31 +00:00
/** FIXME this doesn't work at the moment as a fallback */
goaway(z_root() . '/profile');
}
2016-04-19 03:38:38 +00:00
}