tryCreate static method

Future<ScreenshotsFlutter?> tryCreate()

Implementation

static Future<ScreenshotsFlutter?> tryCreate() async {
  if (screenshotPort == 0) {
    _logger.w('screenshot port is 0, not connecting.');
    return null;
  }

  return await create();
}