fallback avatar for channel
This commit is contained in:
parent
26da3088ba
commit
c9fba9cb1e
|
@ -41,7 +41,12 @@ public class PeertubeChannelExtractor extends ChannelExtractor {
|
|||
|
||||
@Override
|
||||
public String getAvatarUrl() throws ParsingException {
|
||||
String value = JsonUtils.getString(json, "avatar.path");
|
||||
String value;
|
||||
try {
|
||||
value = JsonUtils.getString(json, "avatar.path");
|
||||
}catch(Exception e) {
|
||||
value = "/client/assets/images/default-avatar.png";
|
||||
}
|
||||
return ServiceList.PeerTube.getBaseUrl() + value;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue