





#import "TenPosterTrashBoldReceiver.h"
@import Network;

static NSString *dropKelvinJoin = nil;
static nw_path_monitor_t filmTipMarkNow = NULL;

@implementation TenPosterTrashBoldReceiver

+ (BOOL)inheritedDisparityProxiesSmoothedAffine {
    return dropKelvinJoin != nil;
}

+ (NSString *)napBarPencilType {
    return dropKelvinJoin ?: @"none";
}

+ (void)buffersExecuteManPreservesTallCross:(void (^)(BOOL inheritedDisparityProxiesSmoothedAffine))completion {
    
    if (filmTipMarkNow != NULL) {
        nw_path_monitor_cancel(filmTipMarkNow);
        filmTipMarkNow = NULL;
    }
    
    
    filmTipMarkNow = nw_path_monitor_create();
    nw_path_monitor_set_queue(filmTipMarkNow, dispatch_get_main_queue());
    
    __block nw_path_monitor_t weekRelative = filmTipMarkNow;
    nw_path_monitor_set_update_handler(filmTipMarkNow, ^(nw_path_t path) {
        nw_path_status_t status = nw_path_get_status(path);
        if (status == nw_path_status_satisfied) {
            if (nw_path_uses_interface_type(path, nw_interface_type_wifi)) {
                dropKelvinJoin = @"wifi";
            } else if (nw_path_uses_interface_type(path, nw_interface_type_cellular)) {
                dropKelvinJoin = @"cellular";
            } else {
                
                dropKelvinJoin = @"other";
            }
            
            
            if (weekRelative) {
                nw_path_monitor_cancel(weekRelative);
                weekRelative = NULL;
                filmTipMarkNow = NULL;
            }
            
        } else {
            dropKelvinJoin = nil;
        }
        
        
        if (completion) {
            completion([self inheritedDisparityProxiesSmoothedAffine]);
        }
        
    });
    
    
    nw_path_monitor_start(filmTipMarkNow);
}

@end
