Fix some of the notices in api and login.

This commit is contained in:
Darko
2015-06-23 15:25:30 +02:00
parent 70c4e4e5d7
commit eb4b79d5d9
3 changed files with 7 additions and 16 deletions
+3 -12
View File
@@ -115,20 +115,11 @@ if ($uid != '') {
$releases = new Releases(['Settings' => $page->settings]);
if (isset($_GET['extended']) && $_GET['extended'] == 1) {
$page->smarty->assign('extended', '1');
}
if (isset($_GET['del']) && $_GET['del'] == 1) {
$page->smarty->assign('del', '1');
}
$page->smarty->assign('extended', (isset($_GET['extended']) && $_GET['extended'] == 1 ? '1' : '0'));
$page->smarty->assign('del', (isset($_GET['del']) && $_GET['del'] == 1 ? '1' : '0'));
// Output is either json or xml.
$outputXML = true;
if (isset($_GET['o'])) {
if ($_GET['o'] == 'json') {
$outputXML = false;
}
}
$outputXML = (isset($_GET['o']) && $_GET['o'] == 'json' ? false : true);
switch ($function) {
// Search releases.
@@ -29,10 +29,10 @@
<newznab:attr name="category" value="{$cat}" />
{/foreach}
<newznab:attr name="size" value="{$release.size}" />
{if $release.coverurl != ""}
{if isset($release.coverurl) && $release.coverurl != ""}
<newznab:attr name="coverurl" value="{$serverroot}covers/{$release.coverurl}" />
{/if}
{if $extended=="1"}
{if $extended == "1"}
<newznab:attr name="files" value="{$release.totalpart}" />
<newznab:attr name="poster" value="{$release.fromname|escape:html}" />
{if $release.season != ""}
@@ -4,11 +4,11 @@
{if $error != ''}
<div class="error">{$error}</div>
{/if}
{if $notice != ''}
{if isset($notice) && $notice != ''}
<div class="info">{$notice}</div>
{/if}
{if $confirmed == '' && $sent == ''}
{if isset($confirmed) && $confirmed == '' && isset($sent) && $sent == ''}
<p>
Please enter the email address you used to register and we will send an email to reset your password. If you cannot remember your email, or no longer have access to it, please <a href="{$smarty.const.WWW_TOP}/contact-us">contact us</a>.
</p>