fix(StatusDisplayItem): don't display self-referential quotes
This commit is contained in:
@@ -424,10 +424,14 @@ public abstract class StatusDisplayItem{
|
|||||||
@Override
|
@Override
|
||||||
public void onSuccess(SearchResults results){
|
public void onSuccess(SearchResults results){
|
||||||
if (!results.statuses.isEmpty()){
|
if (!results.statuses.isEmpty()){
|
||||||
status.quote=results.statuses.get(0);
|
Status quote=results.statuses.get(0);
|
||||||
|
// don't show self-referential quotes
|
||||||
|
if(!Objects.equals(status.id, results.statuses.get(0).id)){
|
||||||
|
status.quote=quote;
|
||||||
fragment.updateStatusWithQuote(status);
|
fragment.updateStatusWithQuote(status);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onError(ErrorResponse error){
|
public void onError(ErrorResponse error){
|
||||||
|
|||||||
Reference in New Issue
Block a user