diff --git a/TODO b/TODO
index ae278c4f..3558f366 100644
--- a/TODO
+++ b/TODO
@@ -4,13 +4,10 @@ first major release.
everything related to posts:
- single post view
- basic information
- - uploader's picture
- - remember about support for anonymous uploads
- safety
- source
- image dimensions
- time of last edit
- - time of upload
- time of last feature
- how many times the post was featured
- download
diff --git a/public_html/css/post.css b/public_html/css/post.css
index 2b9599d8..50fefdfb 100644
--- a/public_html/css/post.css
+++ b/public_html/css/post.css
@@ -14,6 +14,12 @@
font-size: 90%;
}
+#post-view-wrapper #sidebar h1 {
+ margin-top: 1.5em;
+ font-weight: normal;
+ font-size: 30px;
+}
+
#post-view-wrapper #sidebar h1:first-of-type {
margin-top: 0;
}
@@ -70,3 +76,11 @@
color: silver;
padding-left: 0.5em;
}
+
+#sidebar .author-box img {
+ float: left;
+ margin-right: 0.5em;
+}
+#sidebar .author-box .author-name {
+ font-weight: bold;
+}
diff --git a/public_html/templates/post.tpl b/public_html/templates/post.tpl
index 259cb69c..3aeb65f8 100644
--- a/public_html/templates/post.tpl
+++ b/public_html/templates/post.tpl
@@ -11,6 +11,30 @@
<% }) %>
+
+
Details
+
+
diff --git a/src/Controllers/UserAvatarController.php b/src/Controllers/UserAvatarController.php
index 1311fcaa..2eb1aca6 100644
--- a/src/Controllers/UserAvatarController.php
+++ b/src/Controllers/UserAvatarController.php
@@ -27,7 +27,14 @@ final class UserAvatarController extends AbstractController
public function getAvatarByName($userName, $size)
{
- $user = $this->userService->getByName($userName);
+ try
+ {
+ $user = $this->userService->getByName($userName);
+ }
+ catch (\Exception $e)
+ {
+ $this->serveBlankFile($size);
+ }
switch ($user->getAvatarStyle())
{
@@ -38,7 +45,7 @@ final class UserAvatarController extends AbstractController
break;
case \Szurubooru\Entities\User::AVATAR_STYLE_BLANK:
- $this->serveFromFile($this->getBlankAvatarSourceContentPath(), $size);
+ $this->serveBlankFile($size);
break;
case \Szurubooru\Entities\User::AVATAR_STYLE_MANUAL:
@@ -46,7 +53,7 @@ final class UserAvatarController extends AbstractController
break;
default:
- $this->serveFromFile($this->getBlankAvatarSourceContentPath(), $size);
+ $this->serveBlankFile($size);
break;
}
}
@@ -63,6 +70,11 @@ final class UserAvatarController extends AbstractController
$this->fileService->serve($thumbnailName);
}
+ private function serveBlankFile($size)
+ {
+ $this->serveFromFile($this->getBlankAvatarSourceContentPath(), $size);
+ }
+
private function getBlankAvatarSourceContentPath()
{
return 'avatars/blank.png';