Code Duplication    Length = 8-10 lines in 2 locations

catalog/index.php 2 locations

@@ 191-198 (lines=8) @@
188
    $Qlisting = $OSCOM_Db->prepare($search_query);
189
190
    if (isset($_GET['manufacturers_id']) && !empty($_GET['manufacturers_id'])) {
191
      if (isset($_GET['filter_id']) && tep_not_null($_GET['filter_id'])) {
192
        $Qlisting->bindInt(':manufacturers_id', $_GET['manufacturers_id']);
193
        $Qlisting->bindInt(':language_id', $OSCOM_Language->getId());
194
        $Qlisting->bindInt(':categories_id', $_GET['filter_id']);
195
      } else {
196
        $Qlisting->bindInt(':language_id', $OSCOM_Language->getId());
197
        $Qlisting->bindInt(':manufacturers_id', $_GET['manufacturers_id']);
198
      }
199
    } else {
200
      if (isset($_GET['filter_id']) && tep_not_null($_GET['filter_id'])) {
201
        $Qlisting->bindInt(':manufacturers_id', $_GET['filter_id']);
@@ 199-208 (lines=10) @@
196
        $Qlisting->bindInt(':language_id', $OSCOM_Language->getId());
197
        $Qlisting->bindInt(':manufacturers_id', $_GET['manufacturers_id']);
198
      }
199
    } else {
200
      if (isset($_GET['filter_id']) && tep_not_null($_GET['filter_id'])) {
201
        $Qlisting->bindInt(':manufacturers_id', $_GET['filter_id']);
202
        $Qlisting->bindInt(':language_id', $OSCOM_Language->getId());
203
        $Qlisting->bindInt(':categories_id', $current_category_id);
204
      } else {
205
        $Qlisting->bindInt(':language_id', $OSCOM_Language->getId());
206
        $Qlisting->bindInt(':categories_id', $current_category_id);
207
      }
208
    }
209
210
    $Qlisting->setPageSet(isset($_GET['view']) && ($_GET['view'] == 'all') ? 999999 : MAX_DISPLAY_SEARCH_RESULTS);
211
    $Qlisting->execute();