how to get a list of files from the directory and pass it to the ListView?Flutter - Implementing a Navigation drawer with a TabBarView widget with dynamic Tab viewFlutter : Can I add a Header Row to a ListViewHow to offset a scaffold widget in Flutter?How to pass List in ImageCarousel?How to pass List _data from main() to Stateful widget (LIstView)?How I can put Widget above Widget using List<Widget> widget in Flutter?How to make Flutter DropDownButton's items window scrollable?passing a listView to another screenFlutter: Image.file won't read image file after taking photo with camera pluginHow to import all Dart files from a Directory?
Are these intended activities legal to do in the USA under the VWP?
Does “comme on était à New York” mean “since” or “as though”?
Is it bad to describe a character long after their introduction?
What is a macro? Difference between macro and function?
How much time passes before we understand that the drought hasn’t ended?
Is this hogweed?
What is the line crossing the Pacific Ocean that is shown on maps?
Details of video memory access arbitration in Space Invaders
How fast can a ship with rotating habitats be accelerated?
Acceleration in Circular motion
Why do I need two parameters in an HTTP parameter pollution attack?
Are metaheuristics ever practical for continuous optimization?
Avoid using C Strings on C++ code to trim leading whitespace
How would an order of Monks that renounce their names communicate effectively?
Do I have to roll to maintain concentration if a target other than me who is affected by my concentration spell takes damage?
How can I convince my reader that I will not use a certain trope?
Different budgets within roommate group
What exactly is a fey/fiend/celestial spirit?
Why isn’t the tax system continuous rather than bracketed?
How do accents of a whole town drift?
The Starks, Parks, Clarks and their kids
Do space suits measure "methane" levels or other biological gases?
What is the difference between handcrafted and learned features
Why does a brace command group need spaces after the opening brace in POSIX Shell Grammar?
how to get a list of files from the directory and pass it to the ListView?
Flutter - Implementing a Navigation drawer with a TabBarView widget with dynamic Tab viewFlutter : Can I add a Header Row to a ListViewHow to offset a scaffold widget in Flutter?How to pass List in ImageCarousel?How to pass List _data from main() to Stateful widget (LIstView)?How I can put Widget above Widget using List<Widget> widget in Flutter?How to make Flutter DropDownButton's items window scrollable?passing a listView to another screenFlutter: Image.file won't read image file after taking photo with camera pluginHow to import all Dart files from a Directory?
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I get the list of files from the user's folder. The names of the files I transfer to the ListView.builder. It's work, but I think, this is bad architecture.
A method _getFilesFromDir() call with a high frequency.
How to make the correct list generation, so as not to update the interface without changing the file list?
class CharacteristList extends StatefulWidget
@override
_CharacteristListState createState() => new _CharacteristListState();
class _CharacteristListState extends State<CharacteristList>
List<String> filesList = new List<String>();
List<String> filesL = new List<String>();
@override
void initState()
super.initState();
filesList = [];
Future<List<String>> _getFilesFromDir() async
filesL = await FilesInDirectory().getFilesFromDir();
setState(()
filesList = filesL;
);
return filesList;
_getFilesCount()
_getFilesFromDir();
int count = filesList.length;
return count;
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Column(
children: <Widget>[
new Expanded(
child: new ListView.builder(
//TODO не успевает сформировать список файлов
itemCount: _getFilesCount(),
itemBuilder: (context, index)
return new CharacteristListItem(filesList[index]);
,
),
),
],
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
dart
add a comment |
I get the list of files from the user's folder. The names of the files I transfer to the ListView.builder. It's work, but I think, this is bad architecture.
A method _getFilesFromDir() call with a high frequency.
How to make the correct list generation, so as not to update the interface without changing the file list?
class CharacteristList extends StatefulWidget
@override
_CharacteristListState createState() => new _CharacteristListState();
class _CharacteristListState extends State<CharacteristList>
List<String> filesList = new List<String>();
List<String> filesL = new List<String>();
@override
void initState()
super.initState();
filesList = [];
Future<List<String>> _getFilesFromDir() async
filesL = await FilesInDirectory().getFilesFromDir();
setState(()
filesList = filesL;
);
return filesList;
_getFilesCount()
_getFilesFromDir();
int count = filesList.length;
return count;
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Column(
children: <Widget>[
new Expanded(
child: new ListView.builder(
//TODO не успевает сформировать список файлов
itemCount: _getFilesCount(),
itemBuilder: (context, index)
return new CharacteristListItem(filesList[index]);
,
),
),
],
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
dart
first thing I can see is you dont have await when calling this function ` await _getFilesFromDir(); //<=here `
– Tree
May 25 '18 at 4:32
add a comment |
I get the list of files from the user's folder. The names of the files I transfer to the ListView.builder. It's work, but I think, this is bad architecture.
A method _getFilesFromDir() call with a high frequency.
How to make the correct list generation, so as not to update the interface without changing the file list?
class CharacteristList extends StatefulWidget
@override
_CharacteristListState createState() => new _CharacteristListState();
class _CharacteristListState extends State<CharacteristList>
List<String> filesList = new List<String>();
List<String> filesL = new List<String>();
@override
void initState()
super.initState();
filesList = [];
Future<List<String>> _getFilesFromDir() async
filesL = await FilesInDirectory().getFilesFromDir();
setState(()
filesList = filesL;
);
return filesList;
_getFilesCount()
_getFilesFromDir();
int count = filesList.length;
return count;
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Column(
children: <Widget>[
new Expanded(
child: new ListView.builder(
//TODO не успевает сформировать список файлов
itemCount: _getFilesCount(),
itemBuilder: (context, index)
return new CharacteristListItem(filesList[index]);
,
),
),
],
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
dart
I get the list of files from the user's folder. The names of the files I transfer to the ListView.builder. It's work, but I think, this is bad architecture.
A method _getFilesFromDir() call with a high frequency.
How to make the correct list generation, so as not to update the interface without changing the file list?
class CharacteristList extends StatefulWidget
@override
_CharacteristListState createState() => new _CharacteristListState();
class _CharacteristListState extends State<CharacteristList>
List<String> filesList = new List<String>();
List<String> filesL = new List<String>();
@override
void initState()
super.initState();
filesList = [];
Future<List<String>> _getFilesFromDir() async
filesL = await FilesInDirectory().getFilesFromDir();
setState(()
filesList = filesL;
);
return filesList;
_getFilesCount()
_getFilesFromDir();
int count = filesList.length;
return count;
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Column(
children: <Widget>[
new Expanded(
child: new ListView.builder(
//TODO не успевает сформировать список файлов
itemCount: _getFilesCount(),
itemBuilder: (context, index)
return new CharacteristListItem(filesList[index]);
,
),
),
],
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
dart
dart
asked May 25 '18 at 3:51
ВячеславВячеслав
521 silver badge9 bronze badges
521 silver badge9 bronze badges
first thing I can see is you dont have await when calling this function ` await _getFilesFromDir(); //<=here `
– Tree
May 25 '18 at 4:32
add a comment |
first thing I can see is you dont have await when calling this function ` await _getFilesFromDir(); //<=here `
– Tree
May 25 '18 at 4:32
first thing I can see is you dont have await when calling this function ` await _getFilesFromDir(); //<=here `
– Tree
May 25 '18 at 4:32
first thing I can see is you dont have await when calling this function ` await _getFilesFromDir(); //<=here `
– Tree
May 25 '18 at 4:32
add a comment |
3 Answers
3
active
oldest
votes
Don't call _getFilesCount() in build(). build() can be called very frequently. Call it in initState() and store the result instead of re-reading over and over again.
It's don't work. Now I'm using FutureBuilder, but I have issue with this
– Вячеслав
May 27 '18 at 4:21
add a comment |
I changed the architecture of the class - I used FutureBuilder.
class _CharacteristListState extends State<CharacteristList>
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Center(
child: new Column(
children: <Widget>[
new FutureBuilder(
future: _inFutureList(),
builder: (BuildContext context, AsyncSnapshot snapshot)
if(snapshot.connectionState == ConnectionState.waiting)
return new Text('Data is loading...');
else
return customBuild(context, snapshot);
)
],
),
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
Widget customBuild(BuildContext context, AsyncSnapshot snapshot)
List<String> values = snapshot.data;
return new Container(
child: new Expanded(
child: new ListView.builder(
itemCount: values.length,
itemBuilder: (context, index)
return new CharacteristListItem(values[index]);
,
),
)
);
Future<List<String>>_inFutureList() async
var filesList = new List<String>();
filesList = await FilesInDirectory().getFilesFromDir();
await new Future.delayed(new Duration(milliseconds: 500));
return filesList;
add a comment |
// add dependancy in pubspec.yaml
path_provider:
import 'dart:io' as io;
import 'package:path_provider/path_provider.dart';
//Declare Globaly
String directory;
List file = new List();
@override
void initState()
// TODO: implement initState
super.initState();
_listofFiles();
// Make New Function
void _listofFiles() async
directory = (await getApplicationDocumentsDirectory()).path;
setState(()
file = io.Directory("$directory/resume/").listSync(); //use your folder name insted of resume.
);
// Build Part
@override
Widget build(BuildContext context)
return MaterialApp(
navigatorKey: navigatorKey,
title: 'List of Files',
home: Scaffold(
appBar: AppBar(
title: Text("Get List of Files with whole Path"),
),
body: Container(
child: Column(
children: <Widget>[
// your Content if there
Expanded(
child: ListView.builder(
itemCount: file.length,
itemBuilder: (BuildContext context, int index)
return Text(file[index].toString());
),
)
],
),
),
),
);
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f50521274%2fhow-to-get-a-list-of-files-from-the-directory-and-pass-it-to-the-listview%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
Don't call _getFilesCount() in build(). build() can be called very frequently. Call it in initState() and store the result instead of re-reading over and over again.
It's don't work. Now I'm using FutureBuilder, but I have issue with this
– Вячеслав
May 27 '18 at 4:21
add a comment |
Don't call _getFilesCount() in build(). build() can be called very frequently. Call it in initState() and store the result instead of re-reading over and over again.
It's don't work. Now I'm using FutureBuilder, but I have issue with this
– Вячеслав
May 27 '18 at 4:21
add a comment |
Don't call _getFilesCount() in build(). build() can be called very frequently. Call it in initState() and store the result instead of re-reading over and over again.
Don't call _getFilesCount() in build(). build() can be called very frequently. Call it in initState() and store the result instead of re-reading over and over again.
answered May 25 '18 at 4:32
Günter ZöchbauerGünter Zöchbauer
351k81 gold badges1098 silver badges1006 bronze badges
351k81 gold badges1098 silver badges1006 bronze badges
It's don't work. Now I'm using FutureBuilder, but I have issue with this
– Вячеслав
May 27 '18 at 4:21
add a comment |
It's don't work. Now I'm using FutureBuilder, but I have issue with this
– Вячеслав
May 27 '18 at 4:21
It's don't work. Now I'm using FutureBuilder, but I have issue with this
– Вячеслав
May 27 '18 at 4:21
It's don't work. Now I'm using FutureBuilder, but I have issue with this
– Вячеслав
May 27 '18 at 4:21
add a comment |
I changed the architecture of the class - I used FutureBuilder.
class _CharacteristListState extends State<CharacteristList>
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Center(
child: new Column(
children: <Widget>[
new FutureBuilder(
future: _inFutureList(),
builder: (BuildContext context, AsyncSnapshot snapshot)
if(snapshot.connectionState == ConnectionState.waiting)
return new Text('Data is loading...');
else
return customBuild(context, snapshot);
)
],
),
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
Widget customBuild(BuildContext context, AsyncSnapshot snapshot)
List<String> values = snapshot.data;
return new Container(
child: new Expanded(
child: new ListView.builder(
itemCount: values.length,
itemBuilder: (context, index)
return new CharacteristListItem(values[index]);
,
),
)
);
Future<List<String>>_inFutureList() async
var filesList = new List<String>();
filesList = await FilesInDirectory().getFilesFromDir();
await new Future.delayed(new Duration(milliseconds: 500));
return filesList;
add a comment |
I changed the architecture of the class - I used FutureBuilder.
class _CharacteristListState extends State<CharacteristList>
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Center(
child: new Column(
children: <Widget>[
new FutureBuilder(
future: _inFutureList(),
builder: (BuildContext context, AsyncSnapshot snapshot)
if(snapshot.connectionState == ConnectionState.waiting)
return new Text('Data is loading...');
else
return customBuild(context, snapshot);
)
],
),
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
Widget customBuild(BuildContext context, AsyncSnapshot snapshot)
List<String> values = snapshot.data;
return new Container(
child: new Expanded(
child: new ListView.builder(
itemCount: values.length,
itemBuilder: (context, index)
return new CharacteristListItem(values[index]);
,
),
)
);
Future<List<String>>_inFutureList() async
var filesList = new List<String>();
filesList = await FilesInDirectory().getFilesFromDir();
await new Future.delayed(new Duration(milliseconds: 500));
return filesList;
add a comment |
I changed the architecture of the class - I used FutureBuilder.
class _CharacteristListState extends State<CharacteristList>
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Center(
child: new Column(
children: <Widget>[
new FutureBuilder(
future: _inFutureList(),
builder: (BuildContext context, AsyncSnapshot snapshot)
if(snapshot.connectionState == ConnectionState.waiting)
return new Text('Data is loading...');
else
return customBuild(context, snapshot);
)
],
),
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
Widget customBuild(BuildContext context, AsyncSnapshot snapshot)
List<String> values = snapshot.data;
return new Container(
child: new Expanded(
child: new ListView.builder(
itemCount: values.length,
itemBuilder: (context, index)
return new CharacteristListItem(values[index]);
,
),
)
);
Future<List<String>>_inFutureList() async
var filesList = new List<String>();
filesList = await FilesInDirectory().getFilesFromDir();
await new Future.delayed(new Duration(milliseconds: 500));
return filesList;
I changed the architecture of the class - I used FutureBuilder.
class _CharacteristListState extends State<CharacteristList>
@override
Widget build(BuildContext context)
return new Scaffold(
appBar: new AppBar(
title: const Text('Список документов'),
),
body: new Center(
child: new Column(
children: <Widget>[
new FutureBuilder(
future: _inFutureList(),
builder: (BuildContext context, AsyncSnapshot snapshot)
if(snapshot.connectionState == ConnectionState.waiting)
return new Text('Data is loading...');
else
return customBuild(context, snapshot);
)
],
),
),
floatingActionButton: new FloatingActionButton(
onPressed: ()
Navigator.push(context,
new MaterialPageRoute(builder: (context)
=> new StartScreen()),
);,
child: new Icon(Icons.add),
),
);
Widget customBuild(BuildContext context, AsyncSnapshot snapshot)
List<String> values = snapshot.data;
return new Container(
child: new Expanded(
child: new ListView.builder(
itemCount: values.length,
itemBuilder: (context, index)
return new CharacteristListItem(values[index]);
,
),
)
);
Future<List<String>>_inFutureList() async
var filesList = new List<String>();
filesList = await FilesInDirectory().getFilesFromDir();
await new Future.delayed(new Duration(milliseconds: 500));
return filesList;
answered May 27 '18 at 16:50
ВячеславВячеслав
521 silver badge9 bronze badges
521 silver badge9 bronze badges
add a comment |
add a comment |
// add dependancy in pubspec.yaml
path_provider:
import 'dart:io' as io;
import 'package:path_provider/path_provider.dart';
//Declare Globaly
String directory;
List file = new List();
@override
void initState()
// TODO: implement initState
super.initState();
_listofFiles();
// Make New Function
void _listofFiles() async
directory = (await getApplicationDocumentsDirectory()).path;
setState(()
file = io.Directory("$directory/resume/").listSync(); //use your folder name insted of resume.
);
// Build Part
@override
Widget build(BuildContext context)
return MaterialApp(
navigatorKey: navigatorKey,
title: 'List of Files',
home: Scaffold(
appBar: AppBar(
title: Text("Get List of Files with whole Path"),
),
body: Container(
child: Column(
children: <Widget>[
// your Content if there
Expanded(
child: ListView.builder(
itemCount: file.length,
itemBuilder: (BuildContext context, int index)
return Text(file[index].toString());
),
)
],
),
),
),
);
add a comment |
// add dependancy in pubspec.yaml
path_provider:
import 'dart:io' as io;
import 'package:path_provider/path_provider.dart';
//Declare Globaly
String directory;
List file = new List();
@override
void initState()
// TODO: implement initState
super.initState();
_listofFiles();
// Make New Function
void _listofFiles() async
directory = (await getApplicationDocumentsDirectory()).path;
setState(()
file = io.Directory("$directory/resume/").listSync(); //use your folder name insted of resume.
);
// Build Part
@override
Widget build(BuildContext context)
return MaterialApp(
navigatorKey: navigatorKey,
title: 'List of Files',
home: Scaffold(
appBar: AppBar(
title: Text("Get List of Files with whole Path"),
),
body: Container(
child: Column(
children: <Widget>[
// your Content if there
Expanded(
child: ListView.builder(
itemCount: file.length,
itemBuilder: (BuildContext context, int index)
return Text(file[index].toString());
),
)
],
),
),
),
);
add a comment |
// add dependancy in pubspec.yaml
path_provider:
import 'dart:io' as io;
import 'package:path_provider/path_provider.dart';
//Declare Globaly
String directory;
List file = new List();
@override
void initState()
// TODO: implement initState
super.initState();
_listofFiles();
// Make New Function
void _listofFiles() async
directory = (await getApplicationDocumentsDirectory()).path;
setState(()
file = io.Directory("$directory/resume/").listSync(); //use your folder name insted of resume.
);
// Build Part
@override
Widget build(BuildContext context)
return MaterialApp(
navigatorKey: navigatorKey,
title: 'List of Files',
home: Scaffold(
appBar: AppBar(
title: Text("Get List of Files with whole Path"),
),
body: Container(
child: Column(
children: <Widget>[
// your Content if there
Expanded(
child: ListView.builder(
itemCount: file.length,
itemBuilder: (BuildContext context, int index)
return Text(file[index].toString());
),
)
],
),
),
),
);
// add dependancy in pubspec.yaml
path_provider:
import 'dart:io' as io;
import 'package:path_provider/path_provider.dart';
//Declare Globaly
String directory;
List file = new List();
@override
void initState()
// TODO: implement initState
super.initState();
_listofFiles();
// Make New Function
void _listofFiles() async
directory = (await getApplicationDocumentsDirectory()).path;
setState(()
file = io.Directory("$directory/resume/").listSync(); //use your folder name insted of resume.
);
// Build Part
@override
Widget build(BuildContext context)
return MaterialApp(
navigatorKey: navigatorKey,
title: 'List of Files',
home: Scaffold(
appBar: AppBar(
title: Text("Get List of Files with whole Path"),
),
body: Container(
child: Column(
children: <Widget>[
// your Content if there
Expanded(
child: ListView.builder(
itemCount: file.length,
itemBuilder: (BuildContext context, int index)
return Text(file[index].toString());
),
)
],
),
),
),
);
edited Mar 25 at 12:37
answered Mar 25 at 12:30
Jay GadariyaJay Gadariya
12 bronze badges
12 bronze badges
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f50521274%2fhow-to-get-a-list-of-files-from-the-directory-and-pass-it-to-the-listview%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
first thing I can see is you dont have await when calling this function ` await _getFilesFromDir(); //<=here `
– Tree
May 25 '18 at 4:32