made basket polymorphic. surprisingly painless, though it looks like a lot of change