Skip to content

Commit

Permalink
fix(ios): verify module class type
Browse files Browse the repository at this point in the history
  • Loading branch information
Gary Mathews authored and sgtcoolguy committed Oct 2, 2019
1 parent 79ac7bb commit 3b12015
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion iphone/TitaniumKit/TitaniumKit/Sources/API/TiHost.m
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ - (id)moduleNamed:(NSString *)name context:(id<TiEvaluator>)context
Class moduleClass = NSClassFromString([NSString stringWithFormat:@"%@Module", name]);
if (moduleClass != nil) {
m = [[moduleClass alloc] _initWithPageContext:context];
if (![m isJSModule]) {
if ([m isKindOfClass:[TiModule class]] && ![m isJSModule]) {
[m setHost:self];
[modules setObject:m forKey:name];
[m release];
Expand Down

0 comments on commit 3b12015

Please sign in to comment.