librefm-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Librefm-commits] [1887] Fix for bug #26651


From: Jørgen Bøhnsdalen
Subject: [Librefm-commits] [1887] Fix for bug #26651
Date: Fri, 29 May 2009 21:27:51 +0000

Revision: 1887
          http://svn.sv.gnu.org/viewvc/?view=rev&root=librefm&revision=1887
Author:   jurgbohn
Date:     2009-05-29 21:27:51 +0000 (Fri, 29 May 2009)
Log Message:
-----------
Fix for bug #26651

Ticket Links:
:-----------
    http://savannah.gnu.org/bugs/?26651

Modified Paths:
--------------
    trunk/nixtape/user-profile.php

Modified: trunk/nixtape/user-profile.php
===================================================================
--- trunk/nixtape/user-profile.php      2009-05-29 20:06:48 UTC (rev 1886)
+++ trunk/nixtape/user-profile.php      2009-05-29 21:27:51 UTC (rev 1887)
@@ -32,7 +32,11 @@
        die();
 }
 
-$user = new User($_GET['user']);
+try {
+       $user = new User($_GET['user']);
+} catch (exception $e) {
+       $error = 'User not found';
+}
 
 if(isset($user->name)) {
 
@@ -77,7 +81,7 @@
 
        $smarty->display('user-profile.tpl');
 } else {
-       $smarty->assign('error', 'User not found');
+       $smarty->assign('error', $error);
        $smarty->assign('details', 'Shall I call in a missing persons report?');
        $smarty->display('error.tpl');
 }





reply via email to

[Prev in Thread] Current Thread [Next in Thread]