On Feb 13, 11:29 am, rohit <[email protected]> wrote:
> On Feb 13, 10:47 am, Jeremy Evans <[email protected]> wrote:
>
> > On Feb 13, 8:16 am, Michael Gliwinski <Michael.Gliwin...@henderson-
>
> > Assuming you are using models, this may work as a global setting:
>
> >   class Sequel::Model
> >     def [](v)
> >       case s = super
> >       when String
> >         s.strip
> >       else
> >         s
> >       end
> >     end
> >   end
>
> Or if you just need this behavior in specific models you can use the
> string_stripper 
> plugin.http://sequel.rubyforge.org/rdoc-plugins/classes/Sequel/Plugins/Strin...

No.  Like the typecasting support, that only affects the setter, not
the getter, so it would not be appropriate for this use case (where a
3rd party is adding data to the database).

Jeremy

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" 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/sequel-talk?hl=en.

Reply via email to