fix compilation: revert AppConfig.enableAdBypass to kDebugMode, fix const Padding with dynamic version
This commit is contained in:
1 parent
54609a3119
commit
4555911ee8
3 files changed
+4
-11
No files matched your search
@@ -107,10 +107,10 @@ class SidebarDrawer extends StatelessWidget {
|
|||||||
|
|
||||||
const Spacer(),
|
const Spacer(),
|
||||||
|
|
||||||
const Padding(
|
Padding(
|
||||||
padding: EdgeInsets.all(20),
|
padding: const EdgeInsets.all(20),
|
||||||
child: Text('ReVoltVPN · v${ReVoltApp.appVersion}', textAlign: TextAlign.center,
|
child: Text('ReVoltVPN · v${ReVoltApp.appVersion}', textAlign: TextAlign.center,
|
||||||
style: TextStyle(color: AppColors.slate, fontSize: 11, letterSpacing: 1),
|
style: const TextStyle(color: AppColors.slate, fontSize: 11, letterSpacing: 1),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -46,11 +46,4 @@ abstract final class AppConfig {
|
|||||||
|
|
||||||
// ── AdMob ──────────────────────────────────────────────────────────────
|
// ── AdMob ──────────────────────────────────────────────────────────────
|
||||||
static const String adUnitId = 'ca-app-pub-0000000000000000/0000000000'; // REPLACE
|
static const String adUnitId = 'ca-app-pub-0000000000000000/0000000000'; // REPLACE
|
||||||
|
|
||||||
// ── Debug ──────────────────────────────────────────────────────────────
|
|
||||||
/// When true, the client skips the real AdMob flow and sends a fake SSV
|
|
||||||
/// callback directly to the server (requires ADMOB_BYPASS=True server-side).
|
|
||||||
/// Set to false in production — the Dart compiler tree-shakes the bypass
|
|
||||||
/// code entirely when this is a compile-time constant false.
|
|
||||||
static const bool enableAdBypass = false;
|
|
||||||
}
|
}
|
||||||
@@ -37,7 +37,7 @@ class HivemindService {
|
|||||||
final url = _url('/session/status?device_id=$deviceId');
|
final url = _url('/session/status?device_id=$deviceId');
|
||||||
|
|
||||||
// ── AD BYPASS (debug only) ────────────────────────────────────────
|
// ── AD BYPASS (debug only) ────────────────────────────────────────
|
||||||
if (AppConfig.enableAdBypass && !skipAdBypass) {
|
if (kDebugMode && !skipAdBypass) {
|
||||||
try {
|
try {
|
||||||
final customData = jsonEncode({'device_id': deviceId, 'nonce': nonce});
|
final customData = jsonEncode({'device_id': deviceId, 'nonce': nonce});
|
||||||
final fakeUrl = _url(
|
final fakeUrl = _url(
|
||||||
|
|||||||
Reference in new issue
Block a user