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

[BUGFIX] Support division by floats smaller than 1 #775

Merged
merged 1 commit into from
Jul 18, 2023

Conversation

s2b
Copy link
Contributor

@s2b s2b commented May 11, 2023

Previously, divisions by a float smaller than 1 in Fluid inline syntax
always resulted in 0. This change adjusts MathExpressionNode
to differentiate between floats and integers correctly.

Resolves: #670
Resolves: https://forge.typo3.org/issues/99214

@tlueder
Copy link
Contributor

tlueder commented Jun 7, 2023

Hey @s2b, Would you mind to rebase this PR since #773 is merged?

@tlueder
Copy link
Contributor

tlueder commented Jun 7, 2023

And I guess this fixes #670 ?

@s2b s2b marked this pull request as ready for review June 9, 2023 09:53
@s2b
Copy link
Contributor Author

s2b commented Jun 9, 2023

I added some edge cases that worked before (e. g. empty string, which results in float(0)). This solution looks simpler and covers more variants.

@s2b s2b requested review from lolli42 and sbuerk and removed request for lolli42 June 9, 2023 10:24
Previously, divisions by a float smaller than 1 in Fluid inline syntax
always resulted in 0. This change adjusts MathExpressionNode
to differentiate between floats and integers correctly.

Resolves: TYPO3#670
Resolves: https://forge.typo3.org/issues/99214
Copy link
Contributor

@sbuerk sbuerk left a comment

Choose a reason for hiding this comment

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

Fine for me.

@sbuerk sbuerk merged commit 16888df into TYPO3:main Jul 18, 2023
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.

Fluid inline notation calculation fails
4 participants