save token and settings also in sqlite db
This commit is contained in:
@ -1,14 +1,14 @@
|
||||
import 'dart:async';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../api/token.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:openmediacentermobile/db/settings_db.dart';
|
||||
|
||||
import '../api/video_api.dart';
|
||||
import '../utils/platform.dart';
|
||||
import '../screen_loading.dart';
|
||||
import '../types/video.dart';
|
||||
import '../types/video_data.dart';
|
||||
import '../utils/platform.dart';
|
||||
import 'info_view.dart';
|
||||
|
||||
import 'videoscreen_desktop.dart'
|
||||
if (dart.library.html) 'videoscreen_mobile.dart';
|
||||
import 'videoscreen_mobile.dart';
|
||||
@ -34,10 +34,8 @@ class _VideoScreenState extends State<VideoScreen> {
|
||||
void initPlayer() async {
|
||||
final videodata = await _videoData;
|
||||
|
||||
final token = await Token.getInstance().getToken();
|
||||
if (token == null) return;
|
||||
|
||||
final path = token.domain + token.videoPath + videodata.movieUrl;
|
||||
final settings = await SettingsDB.getInstance().getSettings();
|
||||
final path = settings.domain + settings.videopath + videodata.movieUrl;
|
||||
|
||||
url = path;
|
||||
}
|
||||
|
Reference in New Issue
Block a user