Skip to content

Commit

Permalink
ForSaleDomains: remove useless auth user check
Browse files Browse the repository at this point in the history
  • Loading branch information
simonesestito committed Jan 13, 2024
1 parent 0527ec2 commit 42686da
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions lib/pages/for_sale_domains.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import 'package:auto_route/annotations.dart';
import 'package:flutter/material.dart';
import 'package:flutter_bloc/flutter_bloc.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
import 'package:gethdomains/bloc/auth/auth_bloc.dart';
import 'package:gethdomains/bloc/selling/selling_bloc.dart';
import 'package:gethdomains/input/validators/domain_input.dart';
import 'package:gethdomains/model/domain.dart';
Expand All @@ -14,13 +13,6 @@ class ForSaleDomainsPage extends StatelessWidget {

@override
Widget build(BuildContext context) {
final authUser = context.select((AuthBloc bloc) {
if (bloc.state is AuthLoggedIn) {
return (bloc.state as AuthLoggedIn).account.address;
}
return null;
});

return Scaffold(
appBar: gethAppBar(
context,
Expand Down Expand Up @@ -72,8 +64,7 @@ class ForSaleDomainsPage extends StatelessWidget {
domain.resoldTimes.toInt(),
),
),
trailing:
_buildBuyDomainButton(context, state, domain, authUser),
trailing: _buildBuyDomainButton(context, state, domain),
);
},
separatorBuilder: (_, __) => const Divider(),
Expand All @@ -89,7 +80,6 @@ class ForSaleDomainsPage extends StatelessWidget {
BuildContext context,
SellingData state,
Domain domain,
String? authUser,
) {
return IconButton(
icon: const Icon(Icons.shopping_cart),
Expand Down

0 comments on commit 42686da

Please sign in to comment.