1
0
mirror of https://github.com/dg/dibi.git synced 2025-08-25 23:16:17 +02:00

improved reflection skills

This commit is contained in:
David Grudl
2008-10-28 01:03:50 +00:00
parent e221a13dda
commit ab892255d3
15 changed files with 242 additions and 140 deletions

View File

@@ -250,7 +250,7 @@ final class DibiTranslator extends DibiObject
case 'by': // key ASC, key DESC
foreach ($value as $k => $v) {
if (is_string($k)) {
$v = (is_string($v) && strcasecmp($v, 'desc')) || $v > 0 ? 'ASC' : 'DESC';
$v = (is_string($v) && strncasecmp($v, 'd', 1)) || $v > 0 ? 'ASC' : 'DESC';
$vx[] = $this->delimite($k) . ' ' . $v;
} else {
$vx[] = $this->delimite($v);