Skip to content

Commit 92bf287

Browse files
committed
Fix bad data handling on client
1 parent 92c3288 commit 92bf287

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

functions/FunctionsExample/CommentCell.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ - (IBAction)didTapAddMessage:(id)sender {
5555
// [END_EXCLUDE]
5656
}
5757
// [END function_error]
58-
self->_resultField.text = result.data[@"text"];
58+
self->_resultField.text = result.data;
5959
}];
6060
// [END function_add_message]
6161
}

functions/FunctionsExampleSwift/CommentCell.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class CommentCell: MDCCollectionViewCell {
4242
// [END_EXCLUDE]
4343
}
4444
// [END function_error]
45-
if let text = (result?.data as? [String: Any])?["text"] as? String {
45+
if let text = result?.data as? String {
4646
self.resultField.text = text
4747
}
4848
}

0 commit comments

Comments
 (0)