fix AC AC detection