MMMarhoon@marhoons·16hc230642#PHP 8.6 gives us clamp() simple enough... right?clamp(50, 100, 0)What comes back? 0? 50? 100? None of them 🤣 ... bounds are backwards 💆♀️correct approach pass bounds in right order: min then max06:07 · Nov 19, 2026 · commit c2306422QuoteReplyHide repliesSDSeguy Damien@dseguy·12hCa produit un erreur! https://php-errors.readthedocs.io/en/latest/messages/must-be-smaller-than-or-equal-to-argument-s3-q$maxr.html…php-errors.readthedocs.iomust be smaller than or equal to argument #3 ($max) - PHP error messages - 1.0.0must be smaller than or equal to argument #3 ($max) - PHP error messages - 1.0.0TranslateReplySBSuliman Benhalim@sulimanbenhalim·12hnamed args make it hard to mix up, clamp(50, min: 0, max: 100) 🙂Reply
SDSeguy Damien@dseguy·12hCa produit un erreur! https://php-errors.readthedocs.io/en/latest/messages/must-be-smaller-than-or-equal-to-argument-s3-q$maxr.html…php-errors.readthedocs.iomust be smaller than or equal to argument #3 ($max) - PHP error messages - 1.0.0must be smaller than or equal to argument #3 ($max) - PHP error messages - 1.0.0TranslateReply
SBSuliman Benhalim@sulimanbenhalim·12hnamed args make it hard to mix up, clamp(50, min: 0, max: 100) 🙂Reply