mirror of
https://github.com/sbondCo/Watcharr.git
synced 2026-08-07 15:25:29 +00:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 0730a99df4 | |||
| 46a043e5b9 | |||
| 87689b201e |
+2
-3
@@ -13,7 +13,6 @@ import (
|
||||
"log/slog"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"os"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
@@ -207,7 +206,7 @@ func AuthRequired(db *gorm.DB) gin.HandlerFunc {
|
||||
}
|
||||
// Parse token
|
||||
token, err := jwt.ParseWithClaims(atoken, &TokenClaims{}, func(token *jwt.Token) (interface{}, error) {
|
||||
return []byte(os.Getenv("JWT_SECRET")), nil
|
||||
return []byte(Config.JWT_SECRET), nil
|
||||
})
|
||||
if err != nil {
|
||||
slog.Error("AuthRequired failed to parse token", "error", err)
|
||||
@@ -587,7 +586,7 @@ func signJWT(user *User) (token string, err error) {
|
||||
})
|
||||
|
||||
// Sign and get the complete encoded token as a string using the secret
|
||||
return jwt.SignedString([]byte(os.Getenv("JWT_SECRET")))
|
||||
return jwt.SignedString([]byte(Config.JWT_SECRET))
|
||||
}
|
||||
|
||||
func hashPassword(password string, p *ArgonParams) (encodedHash string, err error) {
|
||||
|
||||
@@ -207,7 +207,7 @@
|
||||
role="button"
|
||||
tabindex="-1"
|
||||
>
|
||||
<a data-sveltekit-preload-data="tap" href={link}>
|
||||
<a data-sveltekit-preload-data="tap" href={link} class="small-scrollbar">
|
||||
<h2>
|
||||
{title}
|
||||
{#if year}
|
||||
@@ -329,6 +329,7 @@
|
||||
|
||||
& > a {
|
||||
height: 100%;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
h2 {
|
||||
|
||||
@@ -175,7 +175,7 @@
|
||||
role="button"
|
||||
tabindex="-1"
|
||||
>
|
||||
<a data-sveltekit-preload-data="tap" href={link}>
|
||||
<a data-sveltekit-preload-data="tap" href={link} class="small-scrollbar">
|
||||
<h2>
|
||||
{title}
|
||||
{#if year}
|
||||
@@ -277,6 +277,7 @@
|
||||
|
||||
& > a {
|
||||
height: 100%;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
h2 {
|
||||
|
||||
+19
-10
@@ -253,18 +253,27 @@
|
||||
}
|
||||
|
||||
.small-scrollbar {
|
||||
&::-webkit-scrollbar {
|
||||
width: 4.5px;
|
||||
}
|
||||
@supports selector(::-webkit-scrollbar) {
|
||||
&::-webkit-scrollbar {
|
||||
width: 4.5px;
|
||||
}
|
||||
|
||||
&::-webkit-scrollbar-track {
|
||||
background: transparent;
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
&::-webkit-scrollbar-thumb {
|
||||
background-color: rgba(155, 155, 155, 0.5);
|
||||
border-radius: 20px;
|
||||
border: transparent;
|
||||
&::-webkit-scrollbar-thumb {
|
||||
background-color: rgba(155, 155, 155, 0.5);
|
||||
border-radius: 20px;
|
||||
border: transparent;
|
||||
}
|
||||
|
||||
// The scrollbar-width property will always override
|
||||
// -webkit-scrollbar, but since the scrollbars in
|
||||
// chromium look ugly af, we will try to unset scrollbar-width
|
||||
// in these cases and use our manual styling instead to try
|
||||
// mimicking beatiful firefox.
|
||||
scrollbar-width: auto !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user