peritor/simply_stored — Issue #20: name error on hbtm rel when class name has trailing S's 
Author: msolovyov
Created: 2011-10-26 00:34:59+00:00
State: open

To reproduce:
class Department
include SimplyStored::Couch
has_and_belongs_to_many :losses, :storing_keys => true, :class_name => 'Loss'
end

class Loss
include SimplyStored::Couch
has_and_belongs_to_many :departments, :storing_keys => true, :class_name => 'Department'
end

when calling, a_department.losses we get an uninizialized constant error, that it can't find 'Los'

This occurs when in get_class_from_name we pass in the class name of 'Loss' and when calling classify on 'Loss' it shrinks it to 'Los'.