From a7f0efd27f7f23e4ba5928095c8f77a5017cbb8d Mon Sep 17 00:00:00 2001 From: Liam Potter Date: Mon, 26 Sep 2022 00:10:21 +0100 Subject: [PATCH] Fix iOS RCTSwiftLog naming collision with rive-react-native --- CHANGELOG.md | 5 ++++- .../RCTVideoSwiftLog.h} | 2 +- .../RCTVideoSwiftLog.m} | 4 ++-- .../RCTVideoSwiftLog.swift} | 10 +++++----- 4 files changed, 12 insertions(+), 9 deletions(-) rename ios/Video/{RCTSwiftLog/RCTSwiftLog.h => RCTVideoSwiftLog/RCTVideoSwiftLog.h} (93%) rename ios/Video/{RCTSwiftLog/RCTSwiftLog.m => RCTVideoSwiftLog/RCTVideoSwiftLog.m} (93%) rename ios/Video/{RCTSwiftLog/RCTSwiftLog.swift => RCTVideoSwiftLog/RCTVideoSwiftLog.swift} (83%) diff --git a/CHANGELOG.md b/CHANGELOG.md index 267f52b2..0076a2d1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ ## Changelog +### Version 6.0.0-alpha4 +- Fix iOS RCTSwiftLog naming collision [#2868](https://github.com/react-native-video/react-native-video/issues/2868) + ### Version 6.0.0-alpha3 -- fix ios build [#2854](https://gthub.com/react-native-video/react-native-video/pull/2854) +- Fix ios build [#2854](https://github.com/react-native-video/react-native-video/pull/2854) ### Version 6.0.0-alpha.2 diff --git a/ios/Video/RCTSwiftLog/RCTSwiftLog.h b/ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.h similarity index 93% rename from ios/Video/RCTSwiftLog/RCTSwiftLog.h rename to ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.h index 8f9deab7..f9978dc8 100644 --- a/ios/Video/RCTSwiftLog/RCTSwiftLog.h +++ b/ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.h @@ -1,6 +1,6 @@ #import -@interface RCTSwiftLog : NSObject +@interface RCTVideoSwiftLog : NSObject + (void)error:(NSString * _Nonnull)message file:(NSString * _Nonnull)file line:(NSUInteger)line; + (void)warn:(NSString * _Nonnull)message file:(NSString * _Nonnull)file line:(NSUInteger)line; diff --git a/ios/Video/RCTSwiftLog/RCTSwiftLog.m b/ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.m similarity index 93% rename from ios/Video/RCTSwiftLog/RCTSwiftLog.m rename to ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.m index 4e153846..61a38b19 100644 --- a/ios/Video/RCTSwiftLog/RCTSwiftLog.m +++ b/ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.m @@ -1,8 +1,8 @@ #import -#import "RCTSwiftLog.h" +#import "RCTVideoSwiftLog.h" -@implementation RCTSwiftLog +@implementation RCTVideoSwiftLog + (void)info:(NSString *)message file:(NSString *)file line:(NSUInteger)line { diff --git a/ios/Video/RCTSwiftLog/RCTSwiftLog.swift b/ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.swift similarity index 83% rename from ios/Video/RCTSwiftLog/RCTSwiftLog.swift rename to ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.swift index ec39d9b1..99ca8e8a 100644 --- a/ios/Video/RCTSwiftLog/RCTSwiftLog.swift +++ b/ios/Video/RCTVideoSwiftLog/RCTVideoSwiftLog.swift @@ -26,23 +26,23 @@ */ func RCTLogError(_ message: String, _ file: String=#file, _ line: UInt=#line) { - RCTSwiftLog.error(message, file: file, line: line) + RCTVideoSwiftLog.error(message, file: file, line: line) } func RCTLogWarn(_ message: String, _ file: String=#file, _ line: UInt=#line) { - RCTSwiftLog.warn(message, file: file, line: line) + RCTVideoSwiftLog.warn(message, file: file, line: line) } func RCTLogInfo(_ message: String, _ file: String=#file, _ line: UInt=#line) { - RCTSwiftLog.info(message, file: file, line: line) + RCTVideoSwiftLog.info(message, file: file, line: line) } func RCTLog(_ message: String, _ file: String=#file, _ line: UInt=#line) { - RCTSwiftLog.log(message, file: file, line: line) + RCTVideoSwiftLog.log(message, file: file, line: line) } func RCTLogTrace(_ message: String, _ file: String=#file, _ line: UInt=#line) { - RCTSwiftLog.trace(message, file: file, line: line) + RCTVideoSwiftLog.trace(message, file: file, line: line) } func DebugLog(_ message: String) {