refactor to use ServerConfig

This commit is contained in:
csf
2022-12-21 16:24:01 +09:00
parent f5cc55ab3d
commit cba6a3e0ee
4 changed files with 44 additions and 42 deletions

View File

@@ -140,8 +140,7 @@ class _ScanPageState extends State<ScanPage> {
try {
final sc = ServerConfig.decode(data.substring(7));
Timer(Duration(milliseconds: 60), () {
showServerSettingsWithValue(sc.idServer, sc.relayServer, sc.key,
sc.apiServer, gFFI.dialogManager);
showServerSettingsWithValue(sc, gFFI.dialogManager);
});
} catch (e) {
showToast('Invalid QR code');