//
//  NSBundle+GMAILab.m
//  Pods
//
//  Created by cfy on 2020/4/30.
//

#import "NSBundle+GMAILab.h"
#import "GMVerticalFlowLayout.h"

@implementation NSBundle (GMAILabBundle)

+ (instancetype)gm_AILabBundle {
    static NSBundle *bundle = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        bundle = [NSBundle gm_AILabBundleBundle];
    });
    return bundle;
}

+ (NSBundle *)gm_AILabBundleBundle {
    return [self bundleWithURL:[self gm_AILabBundleURL:GMVerticalFlowLayout.class]];
}

+ (NSURL *)gm_AILabBundleURL:(Class)class {
    NSBundle *bundle = [NSBundle bundleForClass:class];
    return [bundle URLForResource:@"GMAILab" withExtension:@"bundle"];
}

@end
