Fix getRedditUriByPath in LinkResolverActivity.

This commit is contained in:
Docile-Alligator 2022-03-25 16:48:35 +08:00
parent c87b724a24
commit 8ac8ea3d8b

View File

@ -60,7 +60,11 @@ public class LinkResolverActivity extends AppCompatActivity {
CustomThemeWrapper mCustomThemeWrapper; CustomThemeWrapper mCustomThemeWrapper;
private Uri getRedditUriByPath(String path) { private Uri getRedditUriByPath(String path) {
return Uri.parse("https://www.reddit.com" + path); if (path.charAt(0) != '/') {
return Uri.parse("https://www.reddit.com/" + path);
} else {
return Uri.parse("https://www.reddit.com" + path);
}
} }
@Override @Override