mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-06-27 01:02:14 +08:00
Fix flutter analyze
This commit is contained in:
@ -402,7 +402,7 @@ class GitHostSetupScreenState extends State<GitHostSetupScreen> {
|
||||
Future _removeExistingClone(String baseDirPath) async {
|
||||
var baseDir = Directory(p.join(baseDirPath, "journal"));
|
||||
var dotGitDir = Directory(p.join(baseDir.path, ".git"));
|
||||
bool exists = await dotGitDir.exists();
|
||||
bool exists = dotGitDir.existsSync();
|
||||
if (exists) {
|
||||
Fimber.d("Removing " + baseDir.path);
|
||||
await baseDir.delete(recursive: true);
|
||||
|
@ -21,8 +21,8 @@ class StateContainer extends StatefulWidget {
|
||||
});
|
||||
|
||||
static StateContainerState of(BuildContext context) {
|
||||
return (context.inheritFromWidgetOfExactType(_InheritedStateContainer)
|
||||
as _InheritedStateContainer)
|
||||
return context
|
||||
.dependOnInheritedWidgetOfExactType<_InheritedStateContainer>()
|
||||
.data;
|
||||
}
|
||||
|
||||
@ -75,7 +75,7 @@ class StateContainerState extends State<StateContainer> {
|
||||
p.join(appState.gitBaseDirectory, appState.remoteGitRepoFolderName));
|
||||
var dotGitDir = Directory(p.join(remoteGitDir.path, ".git"));
|
||||
|
||||
bool exists = await dotGitDir.exists();
|
||||
bool exists = dotGitDir.existsSync();
|
||||
if (exists) {
|
||||
await remoteGitDir.delete(recursive: true);
|
||||
}
|
||||
|
@ -50,12 +50,12 @@ class AppDrawer extends StatelessWidget {
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context).highlightColor,
|
||||
),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: const Padding(
|
||||
padding: EdgeInsets.all(8.0),
|
||||
child: DecoratedBox(
|
||||
decoration: BoxDecoration(
|
||||
image: DecorationImage(
|
||||
image: const AssetImage('assets/icon/icon.png'),
|
||||
image: AssetImage('assets/icon/icon.png'),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
Reference in New Issue
Block a user