Fix loading posts that return 404 from albums
This commit is contained in:
parent
5a015c48f1
commit
11e8a00c1d
|
@ -27,7 +27,7 @@ func FetchAlbum(albumID string) (types.Album, error) {
|
||||||
data := gjson.Parse(string(body))
|
data := gjson.Parse(string(body))
|
||||||
|
|
||||||
album := types.Album{}
|
album := types.Album{}
|
||||||
if data.Get("shared_with_community").Bool() {
|
if data.Get("shared_with_community").Bool() || res.StatusCode == 404 {
|
||||||
album, err = FetchPosts(albumID)
|
album, err = FetchPosts(albumID)
|
||||||
} else {
|
} else {
|
||||||
album, err = ParseAlbum(data)
|
album, err = ParseAlbum(data)
|
||||||
|
|
Loading…
Reference in New Issue