Fixed indexing error causing crash

fixed invalid tuple - int operation error. tuple needed to be indexed