Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Wordless::compile_assets() to actually output compiled assets instead of blank files #70

Merged
merged 1 commit into from Apr 3, 2012
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 2 additions & 5 deletions wordless/wordless.php
Expand Up @@ -120,11 +120,8 @@ public static function compile_assets() {
$compiled_file_path = preg_replace("/\." . $extension . "$/", ".".$preprocessor->to_extension(), $compiled_file_path);

try {
ob_start();
$to_process_file_path = preg_replace("/\." . $extension . "$/", "", $file_path);
$preprocessor->process_file_with_caching($to_process_file_path, Wordless::theme_temp_path());
$compiled_content = ob_get_contents();
ob_end_clean();
$to_process_file_path = preg_replace("/\." . $extension . "$/", "", $file_path);
$compiled_content = $preprocessor->process_file_with_caching($to_process_file_path, Wordless::theme_temp_path());
} catch(WordlessCompileException $e) {
echo "Problems compiling $file_path to $compiled_file_path\n\n";
echo $e;
Expand Down