Pass "null" when copy data is null to iOS pasteboard.string (flutter/engine#14046)
This commit is contained in:
@@ -224,7 +224,11 @@ using namespace flutter;
|
||||
|
||||
- (void)setClipboardData:(NSDictionary*)data {
|
||||
UIPasteboard* pasteboard = [UIPasteboard generalPasteboard];
|
||||
pasteboard.string = data[@"text"];
|
||||
if (data[@"text"]) {
|
||||
pasteboard.string = data[@"text"];
|
||||
} else {
|
||||
pasteboard.string = @"null";
|
||||
}
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
Reference in New Issue
Block a user