src/Neutrino/Database/Schema/Blueprint.php
protected function fluentToReference(Definition $index)
    {
        $columns = (array)$index->get('columns');
        $references = (array)$index->get('references');

        $name = $index->get('name') ?: $this->createReferenceName($columns, $index->get('on'), $references);

        $definition = [
          'columns'           => $columns,
          'referencedTable'   => $index->get('on'),
          'referencedColumns' => $references,
        ];

        if ($index->get('onDelete')) {
            $definition['onDelete'] = $index->get('onDelete');
        }
        if ($index->get('onUpdate')) {
            $definition['onUpdate'] = $index->get('onUpdate');
        }

        return new Reference($name, $definition);
    }
protected function fluentToReference(Definition $index)
    {
        $columns = (array)$index->get('columns');
        $references = (array)$index->get('references');

        $name = $index->get('name') ?: $this->createReferenceName($columns, $index->get('on'), $references);

        $definition = [
          'columns'           => $columns,
          'referencedTable'   => $index->get('on'),
          'referencedColumns' => $references,
        ];

        if ($index->get('onDelete')) {
            $definition['onDelete'] = $index->get('onDelete');
        }
        if ($index->get('onUpdate')) {
            $definition['onUpdate'] = $index->get('onUpdate');
        }

        return new Reference($name, $definition);
    }
Transform a Fluent(Reference) to a \Phalcon\Db\Reference

@param \Neutrino\Database\Schema\Definition $index

@return \Phalcon\Db\Reference