Skip to content

Commit

Permalink
Bugfix on boosts and profiles
Browse files Browse the repository at this point in the history
  • Loading branch information
RasmusLindroth committed Apr 10, 2020
1 parent c772a89 commit 526f26d
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions feed.go
Original file line number Diff line number Diff line change
Expand Up @@ -565,6 +565,9 @@ func (t *TimelineFeed) Input(event *tcell.EventKey) {
if status == nil {
return
}
if status.Reblog != nil {
status = status.Reblog
}
user := status.Account

controls := []ControlItem{
Expand Down Expand Up @@ -684,6 +687,9 @@ func (t *ThreadFeed) Input(event *tcell.EventKey) {
if status == nil {
return
}
if status.Reblog != nil {
status = status.Reblog
}
user := status.Account

controls := []ControlItem{
Expand Down Expand Up @@ -877,19 +883,22 @@ func (u *UserFeed) Input(event *tcell.EventKey) {
if status == nil {
return
}
if status.Reblog != nil {
status = status.Reblog
}
user := status.Account

controls := []ControlItem{
ControlAvatar, ControlThread, ControlSpoiler, ControlCompose,
ControlOpen, ControlReply, ControlMedia, ControlFavorite, ControlBoost,
ControlDelete,
ControlDelete, ControlUser,
}
options := inputOptions(controls)

updated, rc, rt, newS, _ := inputSimple(u.app, event, options, user, status, nil, u)
if updated {
index := u.app.UI.StatusView.GetCurrentItem()
u.statuses[index] = newS
u.statuses[index-1] = newS
}
if rc {
u.RedrawControls()
Expand Down Expand Up @@ -1084,6 +1093,9 @@ func (n *NotificationsFeed) Input(event *tcell.EventKey) {
}

status := notification.Status
if status.Reblog != nil {
status = status.Reblog
}
user := status.Account

controls := []ControlItem{
Expand Down Expand Up @@ -1226,6 +1238,9 @@ func (t *TagFeed) Input(event *tcell.EventKey) {
if status == nil {
return
}
if status.Reblog != nil {
status = status.Reblog
}
user := status.Account

controls := []ControlItem{
Expand Down

0 comments on commit 526f26d

Please sign in to comment.