diff options
-rw-r--r-- | include/config.php | 8 | ||||
-rwxr-xr-x | view/tpl/nav.tpl | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/include/config.php b/include/config.php index bccf0737f..8d98d56fa 100644 --- a/include/config.php +++ b/include/config.php @@ -65,7 +65,7 @@ function get_config($family, $key) { if(! array_key_exists($key,$a->config[$family])) { return false; } - return ((preg_match('|^a:[0-9]+:{.*}$|s', $a->config[$family][$key])) + return ((! is_array($a->config[$family][$key])) && (preg_match('|^a:[0-9]+:{.*}$|s', $a->config[$family][$key])) ? unserialize($a->config[$family][$key]) : $a->config[$family][$key] ); @@ -174,8 +174,8 @@ function get_pconfig($uid,$family, $key, $instore = false) { if((! array_key_exists($family,$a->config[$uid])) || (! array_key_exists($key,$a->config[$uid][$family]))) return false; - - return ((preg_match('|^a:[0-9]+:{.*}$|s', $a->config[$uid][$family][$key])) + + return ((! is_array($a->config[$uid][$family][$key])) && (preg_match('|^a:[0-9]+:{.*}$|s', $a->config[$uid][$family][$key])) ? unserialize($a->config[$uid][$family][$key]) : $a->config[$uid][$family][$key] ); @@ -304,7 +304,7 @@ function get_xconfig($xchan,$family, $key) { if((! array_key_exists($family,$a->config[$xchan])) || (! array_key_exists($key,$a->config[$xchan][$family]))) return false; - return ((preg_match('|^a:[0-9]+:{.*}$|s', $a->config[$xchan][$family][$key])) + return ((! is_array($a->config[$xchan][$family][$key])) && (preg_match('|^a:[0-9]+:{.*}$|s', $a->config[$xchan][$family][$key])) ? unserialize($a->config[$xchan][$family][$key]) : $a->config[$xchan][$family][$key] ); diff --git a/view/tpl/nav.tpl b/view/tpl/nav.tpl index f27afed09..048f53743 100755 --- a/view/tpl/nav.tpl +++ b/view/tpl/nav.tpl @@ -39,7 +39,7 @@ <a class="{{$nav.network.2}}" href="{{$nav.network.0}}" title="{{$nav.network.3}}" ><i class="icon-th nav-icon"></i></a> <span id="net-update" class="nav-notify fakelink" rel="#nav-network-menu"></span> <ul id="nav-network-menu" class="menu-popup notify-menus" rel="network"> - <li id="nav-network-see-all"><a href="{{$nav.network.all.0}}">{{$nav.network.all.1}}</a></li> + {{* <li id="nav-network-see-all"><a href="{{$nav.network.all.0}}">{{$nav.network.all.1}}</a></li> *}} <li id="nav-network-mark-all"><a href="#" onclick="markRead('network'); return false;">{{$nav.network.mark.1}}</a></li> <li class="empty">{{$emptynotifications}}</li> </ul> @@ -51,7 +51,7 @@ <a class="{{$nav.home.2}}" href="{{$nav.home.0}}" title="{{$nav.home.3}}" ><i class="icon-home nav-icon"></i></a> <span id="home-update" class="nav-notify fakelink" rel="#nav-home-menu"></span> <ul id="nav-home-menu" class="menu-popup notify-menus" rel="home"> - <li id="nav-home-see-all"><a href="{{$nav.home.all.0}}">{{$nav.home.all.1}}</a></li> + {{* <li id="nav-home-see-all"><a href="{{$nav.home.all.0}}">{{$nav.home.all.1}}</a></li> *}} <li id="nav-home-mark-all"><a href="#" onclick="markRead('home'); return false;">{{$nav.home.mark.1}}</a></li> <li class="empty">{{$emptynotifications}}</li> </ul> |