diff options
| author | Bharat Mediratta <bharat@menalto.com> | 2009-11-26 12:09:04 -0800 |
|---|---|---|
| committer | Bharat Mediratta <bharat@menalto.com> | 2009-11-26 12:09:04 -0800 |
| commit | 1fd0e14359a7c7164573e4aa897c07680339e713 (patch) | |
| tree | 62b01b88571e53810aa7f3efc2f0f01e727904e2 /modules/gallery/controllers/albums.php | |
| parent | 22823df22098ed1a69d88c2e5fdc30cd90f72c30 (diff) | |
Convert all DB where() calls to take 3 arguments.
Convert all open_paren() calls to and_open() or or_open() as appropriate.
Diffstat (limited to 'modules/gallery/controllers/albums.php')
| -rw-r--r-- | modules/gallery/controllers/albums.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/gallery/controllers/albums.php b/modules/gallery/controllers/albums.php index 19140891..431d98a0 100644 --- a/modules/gallery/controllers/albums.php +++ b/modules/gallery/controllers/albums.php @@ -126,12 +126,12 @@ class Albums_Controller extends Items_Controller { if ($row = Database::instance() ->select(array("name", "slug")) ->from("items") - ->where("parent_id", $album->parent_id) - ->where("id <>", $album->id) - ->open_paren() - ->where("name", $form->edit_item->dirname->value) - ->orwhere("slug", $form->edit_item->slug->value) - ->close_paren() + ->where("parent_id", "=", $album->parent_id) + ->where("id", "<>", $album->id) + ->and_open() + ->where("name", "=", $form->edit_item->dirname->value) + ->orwhere("slug", "=", $form->edit_item->slug->value) + ->close() ->get() ->current()) { if ($row->name == $form->edit_item->dirname->value) { |
