Remove Activate Peer Engine from Mode Switch (Configure Connections Does this Automatically)
continuous-integration/drone/pr Build is passing Details

This commit is contained in:
Sarah Jamie Lewis 2023-09-19 14:54:10 -07:00
parent 545c0c091a
commit 88a4a93326
2 changed files with 0 additions and 3 deletions

View File

@ -236,7 +236,6 @@ class _AddEditProfileViewState extends State<AddEditProfileView> {
onChanged: (bool value) {
Provider.of<ProfileInfoState>(context, listen: false).enabled = value;
if (value) {
Provider.of<FlwtchState>(context, listen: false).cwtch.ActivatePeerEngine(Provider.of<ProfileInfoState>(context, listen: false).onion);
if (Provider.of<ProfileInfoState>(context, listen: false).appearOffline == false) {
Provider.of<FlwtchState>(context, listen: false).cwtch.ConfigureConnections(Provider.of<ProfileInfoState>(context, listen: false).onion, true, true, true);
}
@ -284,7 +283,6 @@ class _AddEditProfileViewState extends State<AddEditProfileView> {
// if the profile is already enabled, then cycle the peer engine...
if (value == true && Provider.of<ProfileInfoState>(context, listen: false).enabled) {
Provider.of<ProfileInfoState>(context, listen: false).deactivatePeerEngine(context);
Provider.of<FlwtchState>(context, listen: false).cwtch.ActivatePeerEngine(onion);
Provider.of<FlwtchState>(context, listen: false).cwtch.ConfigureConnections(onion, false, false, false);
}
}

View File

@ -182,7 +182,6 @@ class _ContactsViewState extends State<ContactsView> {
break;
case ProfileStatusMenu.appearOffline:
Provider.of<ProfileInfoState>(context, listen: false).deactivatePeerEngine(context);
Provider.of<FlwtchState>(context, listen: false).cwtch.ActivatePeerEngine(onion);
Provider.of<FlwtchState>(context, listen: false).cwtch.ConfigureConnections(onion, false, false, false);
break;
case ProfileStatusMenu.editProfile: