Merge branch 'dev' into feature/blog

THAT WAS PAINFUL!
This commit is contained in:
ari melody 2025-11-06 21:24:52 +00:00
commit 3e5ecb9372
Signed by: ari
GPG key ID: CF99829C92678188
99 changed files with 2029 additions and 1010 deletions

View file

@ -3,7 +3,6 @@ package controller
import (
"arimelody-web/model"
"encoding/json"
"errors"
"fmt"
"net/http"
"net/url"
@ -32,7 +31,7 @@ func FetchThreadViewPost(actorID string, postID string) (*model.ThreadViewPost,
res, err := client.Do(req)
if err != nil {
return nil, errors.New(fmt.Sprintf("Failed to call Bluesky API: %v", err))
return nil, fmt.Errorf("Failed to call Bluesky API: %v", err)
}
type Data struct {
@ -41,7 +40,7 @@ func FetchThreadViewPost(actorID string, postID string) (*model.ThreadViewPost,
data := Data{}
err = json.NewDecoder(res.Body).Decode(&data)
if err != nil {
return nil, errors.New(fmt.Sprintf("Invalid response from server: %v", err))
return nil, fmt.Errorf("Invalid response from server: %v", err)
}
return &data.Thread, nil