From faa6c0c05585c0fc3739d0cb24b2322c874775f2 Mon Sep 17 00:00:00 2001 From: "What.CD" Date: Wed, 18 May 2011 08:00:14 +0000 Subject: [PATCH] Allow blank redirect ID when adding artist aliases --- sections/artist/add_alias.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sections/artist/add_alias.php b/sections/artist/add_alias.php index 1e4bc8f1..a59ae7f0 100644 --- a/sections/artist/add_alias.php +++ b/sections/artist/add_alias.php @@ -5,8 +5,9 @@ $ArtistID = $_POST['artistid']; $Redirect = $_POST['redirect']; $AliasName = db_string($_POST['name']); +if(!$Redirect) { $Redirect = 0; } -if(!is_number($ArtistID) || !($Redirect == "0" || is_number($Redirect)) || !$ArtistID) { +if(!is_number($ArtistID) || !($Redirect == 0 || is_number($Redirect)) || !$ArtistID) { error(0); } @@ -14,8 +15,6 @@ error('Blank artist name'); } -if(!$Redirect) { $Redirect = 0; } - /* * In the case of foo, who released an album before changing his name to bar and releasing another * the field shared to make them appear on the same artist page is the ArtistID