FlexImage has a serious bug at the moment because, internally, it stores
the file_store value of its file-stored subclasses in a class variable
@@file_store
This is what happens as a result:
Say I have two Rails model classes, A and B, that I make subclasses of
FlexImage. If I set the self.file_store of each class to two different
directories. FlexImage will set the SAME file_store directory for both A
and B because of the way Ruby currently treats class variables of
inherited classes as shared across all of them.
I didn’t know how to contact the author of FlexImage so I thought I’d
post this here.
Daniel C. wrote:
FlexImage has a serious bug at the moment because, internally, it stores
the file_store value of its file-stored subclasses in a class variable
@@file_store
This is what happens as a result:
Say I have two Rails model classes, A and B, that I make subclasses of
FlexImage. If I set the self.file_store of each class to two different
directories. FlexImage will set the SAME file_store directory for both A
and B because of the way Ruby currently treats class variables of
inherited classes as shared across all of them.
I didn’t know how to contact the author of FlexImage so I thought I’d
post this here.
Multi Class Bug Fixed!
http://beautifulpixel.com/articles/2007/04/12/fleximage_now_mulit_class_safe