kopia lustrzana https://gitlab.com/mysocialportal/relatica
Remove self signed certs override
rodzic
b280a74e40
commit
0db2e86a51
|
@ -1,5 +1,3 @@
|
|||
import 'dart:io';
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_dotenv/flutter_dotenv.dart';
|
||||
import 'package:logging/logging.dart';
|
||||
|
@ -20,14 +18,6 @@ import 'utils/app_scrolling_behavior.dart';
|
|||
void main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
await dotenv.load(fileName: '.env');
|
||||
final inDevMode = dotenv.env['USE_DEV_MODE'] == 'true' ? true : false;
|
||||
if (inDevMode) {
|
||||
print('In Dev Mode');
|
||||
SecurityContext.defaultContext.setTrustedCertificates(
|
||||
'/etc/apache2/certificate/apache-certificate.crt');
|
||||
} else {
|
||||
print('In Regular Mode');
|
||||
}
|
||||
Logger.root.level = Level.ALL;
|
||||
Logger.root.onRecord.listen((event) {
|
||||
final logName = event.loggerName.isEmpty ? 'ROOT' : event.loggerName;
|
||||
|
|
Ładowanie…
Reference in New Issue