Skip to content

Commit

Permalink
Merge pull request #130 from nonmakina/pathFixes
Browse files Browse the repository at this point in the history
Path fixes
  • Loading branch information
towards-a-new-leftypol committed Jan 11, 2021
2 parents cd09c18 + 87b0e97 commit 1b0ae8d
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
4 changes: 2 additions & 2 deletions inc/config.php
Expand Up @@ -794,9 +794,9 @@
// Location of above images.
$config['file_thumb'] = 'static/%s';
// Location of thumbnail to use for spoiler images.
$config['spoiler_image'] = '/static/spoiler.png';
$config['spoiler_image'] = 'static/spoiler.png';
// Location of thumbnail to use for deleted images.
$config['image_deleted'] = '/static/deleted.png';
$config['image_deleted'] = 'static/deleted.png';

// When a thumbnailed image is going to be the same (in dimension), just copy the entire file and use
// that as a thumbnail instead of resizing/redrawing.
Expand Down
2 changes: 0 additions & 2 deletions inc/instance-config.php
Expand Up @@ -266,8 +266,6 @@
$config['stylesheets']['Dark Red'] = 'dark_red.css';
$config['always_noko'] = true;
$config['spoiler_images'] = true;
$config['spoiler_image'] = 'static/spoiler.png';
$config['image_deleted'] = 'static/deleted.png';

//more themes (issue#26)
$config['stylesheets']['Burichan'] = 'burichan.css';
Expand Down
2 changes: 1 addition & 1 deletion templates/post/fileinfo.html
Expand Up @@ -5,7 +5,7 @@
{% for file in post.files %}
<div class="file{% if post.num_files > 1 %} multifile" style="width:{{ file.thumbwidth + 40 }}px"{% else %}"{% endif %}>
{% if file.file == 'deleted' %}
<img class="post-image deleted" src="{{ config.image_deleted }}" alt="" />
<img class="post-image deleted" src="{{ config.root }}{{ config.image_deleted }}" alt="" />
{% else %}
<p class="fileinfo">File: <a href="{{ config.uri_img }}{{ file.file }}" target="_blank">{{ file.file }}</a> <span class="details">
(
Expand Down
6 changes: 3 additions & 3 deletions templates/themes/catalog/theme.php
Expand Up @@ -361,12 +361,12 @@ private function generateRecentPosts($threads) {
}

if (empty($post['file']))
$post['file'] = $config['image_deleted'];
$post['file'] = $config['root'] . $config['image_deleted'];
} else {
$post['file'] = $config['image_deleted'];
$post['file'] = $config['root'] . $config['image_deleted'];
}
} else if($files[0]->thumb == 'spoiler') {
$post['file'] = '/' . $config['spoiler_image'];
$post['file'] = $config['root'] . $config['spoiler_image'];
} else {
$post['file'] = $config['uri_thumb'] . $files[0]->thumb;
}
Expand Down

0 comments on commit 1b0ae8d

Please sign in to comment.