public static void Authenticate(bool isAuth) { if (!isAuth) { return; } AuthHelper.AuthIni(); if (!IsTokenValid()) { throw new Exception("401"); } }