fixed a deprcated error but didn't declare it yet