cleaned up spec code