Advertisement
Guest User

Untitled

a guest
Aug 19th, 2019
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.04 KB | None | 0 0
  1. async function processarFrase(frase) {
  2. frase = limpezaInicial(frase);
  3. let fraseOriginal = frase;
  4. if (frase.match(regexes[0])) {
  5. let match = await limpeza(frase);
  6. frase = match;
  7. }
  8.  
  9. getDictionary(frase, dictionary => {
  10. let grupo = capturarGrupo(fraseOriginal, dictionary);
  11. console.log(fraseOriginal);
  12. console.log("Inserir isso no banco, no campo dataset: " + grupo);
  13. console.log("n");
  14. });
  15. }
  16.  
  17. async function processarFrase(frase) {
  18. let group;
  19. frase = limpezaInicial(frase);
  20. let fraseOriginal = frase;
  21. if (frase.match(regexes[0])) {
  22. let match = await limpeza(frase);
  23. frase = match;
  24. }
  25.  
  26. getDictionary(frase, dictionary => {
  27. let grupo = capturarGrupo(fraseOriginal, dictionary);
  28. console.log(fraseOriginal);
  29. console.log("Inserir isso no banco, no campo dataset: " + grupo);
  30. console.log("n");
  31. group = grupo;
  32. });
  33. return group;
  34. }
  35.  
  36. let grupo = processarFrase("Uma frase qualquer");
  37.  
  38. console.log(grupo)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement