feat(android): implement file sending logic
This commit is contained in:
@@ -41,7 +41,7 @@ class NearbyMessageConverter {
|
||||
|
||||
var result: String?
|
||||
let jsonObject = [
|
||||
"message": message,
|
||||
"content": ["value": message, "type": "text"],
|
||||
"sender": ["id": peerID.displayName, "displayName": name],
|
||||
] as [String : Any]
|
||||
|
||||
|
||||
@@ -102,7 +102,8 @@ public class NearbyServicePlugin: NSObject, FlutterPlugin {
|
||||
}
|
||||
|
||||
case "send":
|
||||
if let message: String = getArgument(for: "message", call: call) {
|
||||
if let content: Dictionary<String, AnyObject> = getArgument(for: "content", call: call),
|
||||
let message: String = content["value"] as? String {
|
||||
if let receiver : Dictionary<String, AnyObject> = getArgument(for: "receiver", call: call),
|
||||
let receiverId : String = receiver["id"] as? String
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user