From 1f9e36868e82fe563028f8c35aaee3c9ba21fa23 Mon Sep 17 00:00:00 2001 From: czaks Date: Sun, 5 Apr 2015 16:20:59 +0200 Subject: [PATCH] ukko: small optimization: move js creation to install time --- templates/themes/ukko/info.php | 1 + templates/themes/ukko/theme.php | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/templates/themes/ukko/info.php b/templates/themes/ukko/info.php index 45a687fc..9a0a53e6 100644 --- a/templates/themes/ukko/info.php +++ b/templates/themes/ukko/info.php @@ -49,6 +49,7 @@ function ukko_install($settings) { if (!file_exists($settings['uri'])) @mkdir($settings['uri'], 0777) or error("Couldn't create " . $settings['uri'] . ". Check permissions.", true); + file_write($settings['uri'] . '/ukko.js', Element('themes/ukko/ukko.js', array())); } } diff --git a/templates/themes/ukko/theme.php b/templates/themes/ukko/theme.php index e1fa0a3f..d6fc303c 100644 --- a/templates/themes/ukko/theme.php +++ b/templates/themes/ukko/theme.php @@ -17,8 +17,6 @@ else { file_write($settings['uri'] . '/index.html', $ukko->build()); } - - file_write($settings['uri'] . '/ukko.js', Element('themes/ukko/ukko.js', array())); } class ukko {