mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-08-30 17:58:59 +00:00
Another take on internal server error
This commit is contained in:
@@ -104,7 +104,7 @@ if (isset($_GET["id"])) {
|
||||
readgzfile($nzbpath);
|
||||
|
||||
// Set the NZB file name.
|
||||
header("Content-Disposition: attachment; filename=" . str_replace(array(',', ' '), '_', $reldata["searchname"]) . ".nzb");
|
||||
header("Content-Disposition: attachment; filename=\"" . str_replace(" ", "_", $reldata["searchname"]) . ".nzb\"");
|
||||
// Get the size of the NZB file.
|
||||
header("Content-Length: " . ob_get_length());
|
||||
header("Content-Type: application/x-nzb");
|
||||
|
||||
@@ -52,11 +52,9 @@ switch($action)
|
||||
$errorStr = 'You must enter a NZBGet password!';
|
||||
} else if (isset($_POST['nzbgetusername']) && empty($_POST['nzbgetusername'])) {
|
||||
$errorStr = 'You must enter a NZBGet username!';
|
||||
}
|
||||
else if (!$users->isValidEmail($_POST['email']))
|
||||
} else if (!$users->isValidEmail($_POST['email'])) {
|
||||
$errorStr = "Your email is not a valid format.";
|
||||
else
|
||||
{
|
||||
} else {
|
||||
$res = $users->getByEmail($_POST['email']);
|
||||
if ($res && $res["ID"] != $userid) {
|
||||
$errorStr = "Sorry, the email is already in use.";
|
||||
|
||||
Reference in New Issue
Block a user