Skip to content

Instantly share code, notes, and snippets.

@jaxoncreed
Created August 1, 2020 20:47
Show Gist options
  • Save jaxoncreed/0e39c42a46eb8230049baf9629d56af1 to your computer and use it in GitHub Desktop.
Save jaxoncreed/0e39c42a46eb8230049baf9629d56af1 to your computer and use it in GitHub Desktop.
export default async function getChatMessages(chatUrl) {
// ...
// Validate that the fetched data is a chat
if (!await isValidChat(chatTtl, dataUrl, nodeUrl)) {
alert(`Document at ${dataUrl} is not a valid chat`)
return null
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment