Dan, sometimes I like this 'feature', and sometimes it catches me out and I wonder wtf is going for an hour or two.
I agree that there is probably no way to change this behaviour as it's so fundamental it would cause untold destruction. you are however more wrong than a wrong thing about the beer. you've obviously never tried Erdinger ;) On 22 Oct 2009, at 16:07, Dan Wilson <[email protected]> wrote: > I'm not sure I agree it is a bug. > > Frankly it seems like a slight change in semantics because the thing > being modified is the event, not just the variable. > > So the following line; > > <cfset something = event.getValue("Beer", "Leffe") /> > > Actually reads as: Please go into the event context, grab the thing > named beer, and put it inside the something variable. Should there > not be anything named beer, then please use Leffe as the value in > the event context. > > Thus the following logic is true and means we all get to have a > Leffe, quite possibly the finest beer on the planet: > > <cfif event.valueExists("Beer") IS false> > <cfset something = event.getValue("Beer", "Leffe") /> > </cfif> > > <cfif "Leffe" IS event.getValue("Beer") and something IS "Leffe"> > <cfset weAllDrinkLeffe() /> > </cfif> > > > As this is a fundamental way MG works and will likely break tons of > old code, I'm not sure how much room we have to modify this > behavior. I would be interested in the ideas, interpretations, > thoughts and debates though. > > > > DW > > > > > > > --~--~---------~--~----~------------~-------~--~----~ Model-Glue Sites: Home Page: http://www.model-glue.com Documentation: http://docs.model-glue.com Bug Tracker: http://bugs.model-glue.com Blog: http://www.model-glue.com/blog You received this message because you are subscribed to the Google Groups "model-glue" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/model-glue?hl=en -~----------~----~----~----~------~----~------~--~---
