INDEX uses a different syntax.

2014-03-02 19:47 GMT+02:00 Dionysis Zindros <notifications@github.com>:

> In database/migration/migrate.php:
>
> > +                foreach ( $keys as $key ) {
> > +                    if ( $key[ 'type' ] == 'unique' || $key[ 'type' ] == 'primary' ) {
> > +                        $type = strtoupper( $key[ 'type' ] );
> > +                        if ( isset( $key[ 'name' ] ) ) {
> > +                            $fields = implode( ',', $key[ 'field' ] );
> > +                            $name = $key[ 'name' ];
> > +                            $args[] = "CONSTRAINT $name $type KEY ( $fields )";
> > +                        }
> > +                        else {
> > +                            foreach ( $key[ 'field' ] as $field ) {
> > +                                $args[] = "$type KEY ( $field )";
> > +                            }
> > +                        }
> > +                    }
> > +                }
> > +                if ( $key[ 'type' ] == 'index' ) {
>
> Why is the last key more significant than all the rest?
>
> --
> Reply to this email directly or view it on GitHub<https://github.com/dionyziz/endofcodes/pull/47/files#r10196429>
> .
>