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

Do not import classes with same name of class name #158

Merged
merged 1 commit into from
Mar 14, 2020

Conversation

fmrodrigues92
Copy link
Contributor

This is a fix.

When I have a relationship with the same table, the command "code:models" will generate a model importing a class with the same name of my class name causing an error.

My fix will ignore that import.

--

In my case, I was trying to add a parent field in my 'users' table with a relationship with 'id' of users.
The App\Models\Base\User users were importing App\Models\User.

@CristianLlanos CristianLlanos merged commit 2fe0684 into reliese:master Mar 14, 2020
@CristianLlanos
Copy link
Member

Thanks!

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

Successfully merging this pull request may close these issues.

None yet

2 participants