Added compatibility with jQuery 1.4
Fixed an index bug
Added clean() to guarded method collection