mirror of
https://github.com/feeddeck/feeddeck.git
synced 2026-05-04 10:08:20 -05:00
[core] Rework Profile Edge Function (#34)
This commit introduces a new "profile-v2" edge function and deprecates the "profile-v1" edge function. We decided to provide a new edge function for all profile related operation to improve the handling of the different operation the edge function is responsible for. The main differences to the "profile-v1" functions are: - Pass the operation id within the request url instead of the body of the request. - Move the operations for accounts (e.g. GitHub) to seperate files, to improve the readability of the function. - Do not require the "sourceType" anymore, instead we are using the operation id and request method to determine the operation which should be executed - The request body is now only used for the data of the corresponding account and not for any other information like the operation id and source information.
This commit is contained in:
@@ -35,7 +35,7 @@ class SettingsAccountsGithub extends StatelessWidget {
|
||||
await Provider.of<ProfileRepository>(
|
||||
context,
|
||||
listen: false,
|
||||
).deleteGithubAccount();
|
||||
).githubDeleteAccount();
|
||||
} catch (_) {}
|
||||
}
|
||||
|
||||
@@ -166,7 +166,7 @@ class _SettingsAccountsGithubAddState extends State<SettingsAccountsGithubAdd> {
|
||||
await Provider.of<ProfileRepository>(
|
||||
context,
|
||||
listen: false,
|
||||
).addGithubAccount(_tokenController.text);
|
||||
).githubAddAccount(_tokenController.text);
|
||||
|
||||
setState(() {
|
||||
_isLoading = false;
|
||||
|
||||
Reference in New Issue
Block a user