Pass to `ColumnInterface::dbTypecast()` non-null and non-expression values only
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 216
- Forks
- 51
- Avg merge
- 3d 10h
- Merged PRs (30d)
- 2
Description
Seems, all implementations of ColumnInterface::dbTypecast() checks value on null and ExpressionInterface and return it as is for those values:
if ($value === null || $value instanceof ExpressionInterface) {
return $value;
}
We can check it before call dbTypecast() and simplify simplify both existing implementations and the creation of custom ones.
⚠️ Don't implement it before start version 3.0 development.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating ColumnInterface::dbTypecast(), its implementations, and the callers that pass values to it; inspect how ExpressionInterface and null are currently handled. Confirm the change is appropriate for the 3.0 development window, then run the relevant database test suite and verify that null and expression values remain unchanged while other values are typecast.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- databases
- Issue type
- Refactor
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100