Removed reliance on class-level indexing