add middleware writeLog
This commit is contained in:
parent
bc19538431
commit
fe6ef901b8
|
|
@ -44,11 +44,15 @@ export function loggerAPI(request, response, location) {
|
|||
response.getStatus() +
|
||||
" - " +
|
||||
location +
|
||||
"\n------------PAYLOAD-----------\n" +
|
||||
"\n------PAYLOAD------\n" +
|
||||
JSON.stringify(request.all()) +
|
||||
"\n--------------DATA-------------\n" +
|
||||
"\n-------DATA--------\n" +
|
||||
JSON.stringify(body) +
|
||||
"\n-------------------------------";
|
||||
"\n-------HEADERS--------\n" +
|
||||
JSON.stringify(request.headers()) +
|
||||
"\n-------PARAMS--------\n" +
|
||||
JSON.stringify(request.params()) +
|
||||
"\n\n======================================================================\n======================================================================";
|
||||
|
||||
fs.exists(fileName, async (exists) => {
|
||||
if (exists) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue