File tree 2 files changed +15
-6
lines changed
2 files changed +15
-6
lines changed Original file line number Diff line number Diff line change @@ -3,12 +3,24 @@ const router = express.Router();
3
3
const fs = require ( "fs" ) ;
4
4
const os = require ( "os" ) ;
5
5
const path = require ( "path" ) ;
6
+ const {
7
+ getRandomInt,
8
+ getRandomBin,
9
+ getRandomHex,
10
+ generateToken,
11
+ ordenarUsuario,
12
+ pesqUsuario,
13
+ validadeApiKey,
14
+ unauthorized,
15
+ forbidden,
16
+ formatDate,
17
+ conversorSimEnao,
18
+ } = require ( "npm-package-nodejs-utils-lda" ) ;
6
19
7
20
const files = __dirname + "/src/" ;
8
21
const path_css = files + "css/" ;
9
22
const path_js = files + "js/" ;
10
23
const path_pages = files + "pages/" ;
11
- const forbiddenFilePath = path . join ( path_pages , "forbidden.html" ) ;
12
24
const indexFilePath = path . join ( path_pages , "index.html" ) ;
13
25
const hostFilePath = path . join ( path_pages , "host.html" ) ;
14
26
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ const router = express.Router();
3
3
const fs = require ( "fs" ) ;
4
4
const path = require ( "path" ) ;
5
5
const multer = require ( "multer" ) ;
6
- const { fetchGet, fetchPost } = require ( "./modules/fetchModule.js " ) ;
6
+ const { fetchGet, fetchPost } = require ( "npm-package-nodejs-utils-lda " ) ;
7
7
const {
8
8
getRandomInt,
9
9
getRandomBin,
@@ -16,7 +16,7 @@ const {
16
16
forbidden,
17
17
formatDate,
18
18
conversorSimEnao,
19
- } = require ( "./modules/ utils.js " ) ;
19
+ } = require ( "npm-package-nodejs- utils-lda " ) ;
20
20
21
21
const storagePages = multer . diskStorage ( {
22
22
destination : ( req , file , cb ) => {
@@ -32,9 +32,6 @@ const storagePages = multer.diskStorage({
32
32
} ,
33
33
} ) ;
34
34
35
- router . use ( express . urlencoded ( { extended : true } ) ) ;
36
- router . use ( express . json ( ) ) ;
37
-
38
35
// obter o banco de dados de arquivos hosteados automaticamente
39
36
router . get ( "/host=data" , ( req , res ) => {
40
37
console . log ( "SISTEMA <OBTER> <ARQUIVO>: " + req . url ) ;
You can’t perform that action at this time.
0 commit comments