Revert "add cleanup url util for removing stuff like `www.` from urls"

This reverts commit a8ac98284a.
This commit is contained in:
krawieck 2020-10-05 13:44:41 +02:00
parent 01221bdd03
commit 5697405e32
2 changed files with 1 additions and 12 deletions

View File

@ -1,10 +0,0 @@
String cleanUpUrl(String url) {
if (url.startsWith('https://')) {
url = url.substring(8);
}
if (url.startsWith('www.')) {
url = url.substring(4);
}
return url;
}

View File

@ -13,7 +13,6 @@ import '../hooks/delayed_loading.dart';
import '../hooks/logged_in_action.dart';
import '../pages/full_post.dart';
import '../url_launcher.dart';
import '../util/cleanup_url.dart';
import '../util/extensions/api.dart';
import '../util/goto.dart';
import 'bottom_modal.dart';
@ -210,7 +209,7 @@ class Post extends HookWidget {
text: '@',
style: TextStyle(fontWeight: FontWeight.w300)),
TextSpan(
text: cleanUpUrl(instanceUrl),
text: instanceUrl,
style: TextStyle(fontWeight: FontWeight.w600),
recognizer: TapGestureRecognizer()
..onTap =