fixing panic