Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with bake when trying to add field name starting with "To" #147

Closed
choma opened this issue Nov 9, 2015 · 3 comments
Closed

Issue with bake when trying to add field name starting with "To" #147

choma opened this issue Nov 9, 2015 · 3 comments
Labels
Milestone

Comments

@choma
Copy link

choma commented Nov 9, 2015

When I try to add a column named "token" to the Users table like this:

bin/cake bake migration AddTokenToUsers token:string

bake generate this code:

public function change()
{
    $table = $this->table('ken_to_users');

Then, when I try to run the migration I get

[RuntimeException]                         
  Cannot update a table that doesn't exist!

It works if I do it this way:

bin/cake bake migration AddtokenToUsers token:string
@antograssiot
Copy link
Contributor

fixed in #148

@HavokInspiration HavokInspiration added this to the 1.5 milestone Dec 1, 2015
@acjbizar
Copy link

acjbizar commented Mar 6, 2021

It appears this is still the case when the second part of a column name starts with To. I just noticed this running the following instruction:

cake bake migration --plugin DeZelf AddConfirmationTokenToUsers confirmation_token:string?[191]

@othercorey
Copy link
Member

@acjbizar Please open a new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants