Skip to content

fix: replace console.warn with p5._friendlyError in light.js and material.js (fixes #8595)#8596

Open
MASTERsj01 wants to merge 1 commit intoprocessing:mainfrom
MASTERsj01:fix/light-material-console-to-fes
Open

fix: replace console.warn with p5._friendlyError in light.js and material.js (fixes #8595)#8596
MASTERsj01 wants to merge 1 commit intoprocessing:mainfrom
MASTERsj01:fix/light-material-console-to-fes

Conversation

@MASTERsj01
Copy link

Summary

Replaces 9 console.warn calls across light.js (6) and material.js (3) with p5._friendlyError().

Resolves #8595

Changes

File Count Warnings
light.js 6 lightFalloff (4), spotLight (2)
material.js 3 textureMode (1), blendMode (2)

All messages now respect p5.disableFriendlyErrors.

Notes

  • All existing tests pass (1913 passing)
  • 2 files changed: 33 insertions, 25 deletions

…rial.js

- light.js: Replace 6 console.warn calls with p5._friendlyError()
  (lightFalloff negative values, spotLight argument format, concentration)
- material.js: Replace 3 console.warn calls with p5._friendlyError()
  (textureMode invalid mode, blendMode DARKEST/LIGHTEST unsupported)
- All messages now respect p5.disableFriendlyErrors setting
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.

light.js + material.js: replace console.warn with Friendly Error System (FES)

1 participant