From 24b4ce7925a99e6e10ecbea5d880fd24ab69a02b Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Wed, 30 Dec 2015 13:57:32 +0000 Subject: Change listfiles filesize to size, size and mtime not user-friendly, use posix.stat over fs.stat, use new format functions --- dhcp-listfiles-html.lsp | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) (limited to 'dhcp-listfiles-html.lsp') diff --git a/dhcp-listfiles-html.lsp b/dhcp-listfiles-html.lsp index 9af11cd..f12e321 100644 --- a/dhcp-listfiles-html.lsp +++ b/dhcp-listfiles-html.lsp @@ -3,20 +3,6 @@ htmlviewfunctions = require("htmlviewfunctions") html = require("acf.html") %> -<% -function convertsize(size) - if string.find(size, "k$") then - return tonumber(string.match(size, "[%d.]*")) * 1024.0 - elseif string.find(size, "M$") then - return tonumber(string.match(size, "[%d.]*")) * 1024.0 * 1024.0 - elseif string.find(size, "G$") then - return tonumber(string.match(size, "[%d.]*")) + 1024.0 * 1024.0 * 1024.0 - else - return tonumber(string.match(size, "[%d.]*")) - end -end -%> -