function getTorrent($user = null) { \core\Mysqli::$default = "gazelle"; \config\Conf::$torrentpass = $user; if (is_null($user)) { $user = String::random(5); $pass = String::random(32); \config\Conf::$torrentpass = $pass; Requete::addUser($user, $pass, "1"); } $a = Torrents_files::getFile(12); $to = new Torrent($a->file); $to->announce(Torrent::getAnnounceUser()); $to->send(); }