import 'dart:io';

import 'package:flutter/material.dart';

import 'app/app.dart';
export 'app/app.dart';

void main() {
  HttpOverrides.global = _InternalCertificateHttpOverrides();
  runApp(const MyLisApp());
}

class _InternalCertificateHttpOverrides extends HttpOverrides {
  @override
  HttpClient createHttpClient(SecurityContext? context) {
    return super.createHttpClient(context)
      ..badCertificateCallback = (certificate, host, port) {
        debugPrint(
          'MyLIS menerima sertifikat internal untuk $host:$port '
          'issuer=${certificate.issuer}',
        );
        return true;
      };
  }
}
