function handleResource(resource) {
if (resource.type === ShareResource.FilePathType) {
handleSharedFilePath(resource.filePath)
} else if (resource.type === ShareResource.StringDataType) {
handleSharedData(resource.name, resource.data)
} else {
console.warn("Unknown resource type:", resource.type)
showSharingError()
}
}