Explorar el Código

优化日志获取

hl hace 7 meses
padre
commit
9748ec51d9
Se han modificado 1 ficheros con 0 adiciones y 5 borrados
  1. 0 5
      src/utils/file.js

+ 0 - 5
src/utils/file.js

@@ -199,11 +199,6 @@ async function readLinesFromEnd(filePath, maxLines) {
             if (lines.length >= maxLines) {
                 break;
             }
-
-            position -= chunkSize;
-            if (position < 0) {
-                position = 0;
-            }
         }
     } else {
         let forNum = (fileSize / chunkSize) + 1;