fix attachment deletion crash bug

Reduce bits of common bits in theme stylesheets.
This commit is contained in:
Azareal 2020-02-19 08:43:55 +10:00
parent 5029e6b73f
commit 7e3cd48284
4 changed files with 19 additions and 18 deletions

View File

@ -92,9 +92,11 @@ func deleteAttachment(w http.ResponseWriter, r *http.Request, user c.User, aid i
err := c.DeleteAttachment(aid) err := c.DeleteAttachment(aid)
if err == sql.ErrNoRows { if err == sql.ErrNoRows {
return c.NotFoundJSQ(w, r, nil, js) return c.NotFoundJSQ(w, r, nil, js)
} } else if err != nil {
return c.InternalErrorJSQ(err, w, r, js) return c.InternalErrorJSQ(err, w, r, js)
} }
return nil
}
// TODO: Stop duplicating this code // TODO: Stop duplicating this code
// TODO: Use a transaction here // TODO: Use a transaction here

View File

@ -262,8 +262,8 @@ h1, h2, h3, h4, h5 {
-webkit-margin-after:0; -webkit-margin-after:0;
margin-block-start:0; margin-block-start:0;
margin-block-end:0; margin-block-end:0;
margin-top: 0px; margin-top:0;
margin-bottom: 0px; margin-bottom:0;
font-weight: normal; font-weight: normal;
white-space: nowrap; white-space: nowrap;
} }

View File

@ -163,7 +163,6 @@ a {
.rowblock:not(.opthead):not(.colstack_head):not(.rowhead) .rowitem { .rowblock:not(.opthead):not(.colstack_head):not(.rowhead) .rowitem {
font-size: 15px; /*16px*/ font-size: 15px; /*16px*/
} }
.rowblock:last-child, .colstack_item:last-child { .rowblock:last-child, .colstack_item:last-child {
padding-bottom: 10px; padding-bottom: 10px;
} }
@ -183,8 +182,8 @@ h1, h2, h3, h4, h5 {
-webkit-margin-after:0; -webkit-margin-after:0;
margin-block-start:0; margin-block-start:0;
margin-block-end:0; margin-block-end:0;
margin-top: 0px; margin-top:0;
margin-bottom: 0px; margin-bottom:0;
font-weight: normal; font-weight: normal;
} }
.rowsmall { .rowsmall {