Doctrine 1
  1. Doctrine 1
  2. DC-748

Warning: implode(): Invalid arguments passed in /Doctrine/Table.php on line on line 922

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.2.2
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      mysql 5.1.40, php 5.3.1

      Description

      Calling to function implode() while not checked if second argument is an array.
      Arrives anywhere on trying to create and get Doctrine_Query and Doctrine_Collection objects. Also on using Doctrine_Cli commands.
      Here is a fragment that generates warning:

      class Doctrine_Table extends Doctrine_Configurable implements Countable
      {
      ...

      public function unique($fields, $options = array(), $createdUniqueIndex = true)
      {
      if ($createdUniqueIndex)

      { $name = implode('_', $fields) . '_unqidx'; // this line generates warning $definition = array('type' => 'unique', 'fields' => $fields); $this->addIndex($name, $definition); }

      $this->_uniques[] = array($fields, $options);
      }
      ...
      }

      1. Table.php
        93 kB
        Victor Paladiychuk

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            Jonathan H. Wage
            Reporter:
            Victor Paladiychuk
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated: