mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-20 05:13:54 -07:00
Ternary operator could be simplified.
(cherry picked from commit 57f0cd7
)
This commit is contained in:
parent
fc8d71de5c
commit
02a06e68c9
3 changed files with 3 additions and 3 deletions
|
@ -211,7 +211,7 @@ foreach ($cat_forums as $cid => $c) {
|
||||||
));
|
));
|
||||||
|
|
||||||
$template->assign_vars(array(
|
$template->assign_vars(array(
|
||||||
'H_C_AL_MESS' => ($hide_cat_opt && !$showhide) ? true : false,
|
'H_C_AL_MESS' => ($hide_cat_opt && !$showhide),
|
||||||
));
|
));
|
||||||
|
|
||||||
if (!$showhide && isset($hide_cat_user[$cid]) && !$viewcat) {
|
if (!$showhide && isset($hide_cat_user[$cid]) && !$viewcat) {
|
||||||
|
|
|
@ -253,7 +253,7 @@ function physical_filename_already_stored($filename)
|
||||||
$num_rows = DB()->num_rows($result);
|
$num_rows = DB()->num_rows($result);
|
||||||
DB()->sql_freeresult($result);
|
DB()->sql_freeresult($result);
|
||||||
|
|
||||||
return ($num_rows == 0) ? false : true;
|
return $num_rows != 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -774,7 +774,7 @@ class template
|
||||||
if (!$count_if) {
|
if (!$count_if) {
|
||||||
$keyword_type = XS_TAG_IF;
|
$keyword_type = XS_TAG_IF;
|
||||||
}
|
}
|
||||||
$str = $this->compile_tag_if($params_str, $keyword_type == XS_TAG_IF ? false : true);
|
$str = $this->compile_tag_if($params_str, $keyword_type != XS_TAG_IF);
|
||||||
if ($str) {
|
if ($str) {
|
||||||
$compiled[] = '<?php ' . $str . ' ?>';
|
$compiled[] = '<?php ' . $str . ' ?>';
|
||||||
if ($keyword_type == XS_TAG_IF) {
|
if ($keyword_type == XS_TAG_IF) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue