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

Fix up PHPStan errors. #1948

Merged
merged 3 commits into from
Jan 23, 2023
Merged

Fix up PHPStan errors. #1948

merged 3 commits into from
Jan 23, 2023

Conversation

dereuromark
Copy link
Contributor

Fix some more PHPStan issues of level 7

~120 issues left

Copy link
Contributor

@mringler mringler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice also

src/Propel/Generator/Reverse/PgsqlSchemaParser.php Outdated Show resolved Hide resolved
@@ -633,6 +668,9 @@ protected function addSequences(Database $database): void
AND c.relkind = 'S'
AND n.nspname IN ($searchPath);
");
if ($stmt === false) {
throw new RuntimeException('prepare() returned no statement.');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uff, thank you for adding all those! Might make sense to change prepare() to throw an exception instead of doing the stupid false return

Copy link
Contributor

@mringler mringler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, so that is how those suggestions work.
I never accept them, because they lead to merge commits in my feature branch, but if you like them, I'll try to think of them in the future.

src/Propel/Generator/Reverse/PgsqlSchemaParser.php Outdated Show resolved Hide resolved
src/Propel/Generator/Reverse/SqliteSchemaParser.php Outdated Show resolved Hide resolved
Co-authored-by: Moritz Ringler <m@mringler.net>
@dereuromark
Copy link
Contributor Author

If we squash merge, they will not :)
And we should do that with such dirty commits anyway then by default.

Co-authored-by: Moritz Ringler <m@mringler.net>
@dereuromark dereuromark merged commit de6deb4 into master Jan 23, 2023
@dereuromark dereuromark deleted the bugfix/phpstan-l7 branch January 23, 2023 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants