Joomla CMS [#27257] Fix a typo in the publish method of jtablenested.Originally identified i... #680

Merged
merged 4 commits into from Jan 2, 2012

Conversation

Projects
None yet
4 participants
Contributor

elinw commented Dec 29, 2011

Fix a typo in the publish method of jtablenested.Originally identified in CMS

tracker issue #27257

Contributor

joomla-jenkins commented Dec 29, 2011

Unit testing complete. There were 0 failures and 0 errors from 1971 tests and 11142 assertions.
Checkstyle analysis reported 199 warnings and 0 errors.

@marcel-kanter marcel-kanter commented on an outdated diff Dec 29, 2011

libraries/joomla/database/tablenested.php
@@ -974,7 +974,7 @@ public function publish($pks = null, $state = 1, $userId = 0)
// Update and cascade the publishing state.
$query = $this->_db->getQuery(true)->update($this->_db->quoteName($this->_tbl))->set('published = ' . (int) $state)
- ->where('(lft > ' . (int) $this->lft . ' AND rgt < ' . (int) $this->rgt . ')' . ' OR ' . $k . ' = ' . (int) $pk);
+ ->where('(lft > ' . (int) $node->lft . ' AND rgt < ' . (int) $this->rgt . ')' . ' OR ' . $k . ' = ' . (int) $pk);
@marcel-kanter

marcel-kanter Dec 29, 2011

patch incomplete the second this should be node too.

  •    ->where('(lft > ' . (int) $this->lft . ' AND rgt < ' . (int) $this->rgt . ')' . ' OR ' . $k . ' = ' . (int) $pk);
    
  •    ->where('(lft > ' . (int) $node->lft . ' AND rgt < ' . (int) $node->rgt . ')' . ' OR ' . $k . ' = ' . (int) $pk);
    

(btw. the worst readable coding style. some features are nice to have but should not be used to improve readability and compatibility)

Contributor

joomla-jenkins commented Dec 31, 2011

Build triggered by changes to the head.

Unit testing complete. There were 0 failures and 0 errors from 1971 tests and 11142 assertions.
Checkstyle analysis reported 199 warnings and 0 errors.

Contributor

joomla-jenkins commented Jan 1, 2012

Build triggered by changes to the head.

Unit testing complete. There were 0 failures and 0 errors from 1971 tests and 11142 assertions.
Checkstyle analysis reported 199 warnings and 0 errors.

@chdemko chdemko added a commit that referenced this pull request Jan 2, 2012

@chdemko chdemko Merge pull request #680 from elinw/jtablenested
Fix a typo in the publish method of jtablenested.Originally identified i...
2396dd9

@chdemko chdemko merged commit 2396dd9 into joomla:staging Jan 2, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment