fix: downgrade share_plus to v10.1.4 due to Android build errors with v12

This commit is contained in:
Patrick Britton 2026-02-09 16:10:41 -06:00
parent 2377899d72
commit 2dd1fe3ac2
6 changed files with 9 additions and 9 deletions

View file

@ -1233,7 +1233,7 @@ class _ThreadedConversationScreenState extends ConsumerState<ThreadedConversatio
try { try {
await SharePlus.instance.share(ShareParams(text: text)); await Share.share(text);
} catch (e) { } catch (e) {
if (mounted) { if (mounted) {
ScaffoldMessenger.of(context).showSnackBar( ScaffoldMessenger.of(context).showSnackBar(

View file

@ -90,7 +90,7 @@ class _BlockedUsersScreenState extends ConsumerState<BlockedUsersScreen> {
final file = File('${directory.path}/sojorn_blocklist.json'); final file = File('${directory.path}/sojorn_blocklist.json');
await file.writeAsString(jsonStr); await file.writeAsString(jsonStr);
await SharePlus.instance.share(ShareParams(files: [XFile(file.path)], text: 'My Sojorn Blocklist')); await Share.shareXFiles([XFile(file.path)], text: 'My Sojorn Blocklist');
} catch (e) { } catch (e) {
if (mounted) { if (mounted) {
ScaffoldMessenger.of(context).showSnackBar( ScaffoldMessenger.of(context).showSnackBar(

View file

@ -460,7 +460,7 @@ class _QuipsFeedScreenState extends ConsumerState<QuipsFeedScreen>
void _shareQuip(Quip quip) { void _shareQuip(Quip quip) {
final url = AppRoutes.getQuipUrl(quip.id); final url = AppRoutes.getQuipUrl(quip.id);
final text = '${quip.caption}\n\n$url\n\n— @${quip.username} on Sojorn'; final text = '${quip.caption}\n\n$url\n\n— @${quip.username} on Sojorn';
SharePlus.instance.share(ShareParams(text: text)); Share.share(text);
} }

View file

@ -113,7 +113,7 @@ class _PostActionsState extends ConsumerState<PostActions> {
final text = '${widget.post.body}\n\n— @$handle on sojorn'; final text = '${widget.post.body}\n\n— @$handle on sojorn';
try { try {
await SharePlus.instance.share(ShareParams(text: text)); await Share.share(text);
} catch (e) { } catch (e) {
_showError('Unable to share right now.'); _showError('Unable to share right now.');
} }

View file

@ -1617,18 +1617,18 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: share_plus name: share_plus
sha256: "14c8860d4de93d3a7e53af51bff479598c4e999605290756bbbe45cf65b37840" sha256: fce43200aa03ea87b91ce4c3ac79f0cecd52e2a7a56c7a4185023c271fbfa6da
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "12.0.1" version: "10.1.4"
share_plus_platform_interface: share_plus_platform_interface:
dependency: transitive dependency: transitive
description: description:
name: share_plus_platform_interface name: share_plus_platform_interface
sha256: "88023e53a13429bd65d8e85e11a9b484f49d4c190abbd96c7932b74d6927cc9a" sha256: cc012a23fc2d479854e6c80150696c4a5f5bb62cb89af4de1c505cf78d0a5d0b
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "6.1.0" version: "5.0.2"
shared_preferences: shared_preferences:
dependency: "direct main" dependency: "direct main"
description: description:

View file

@ -25,7 +25,7 @@ dependencies:
# UI & Utilities # UI & Utilities
cupertino_icons: ^1.0.8 cupertino_icons: ^1.0.8
google_fonts: ^8.0.1 google_fonts: ^8.0.1
share_plus: ^12.0.1 share_plus: ^10.1.4
timeago: ^3.7.0 timeago: ^3.7.0
url_launcher: ^6.3.2 url_launcher: ^6.3.2
image_picker: ^1.1.2 image_picker: ^1.1.2