mirror of
https://github.com/lollipopkit/flutter_server_box.git
synced 2026-02-23 00:24:20 +01:00
#97 fix
This commit is contained in:
@@ -2,8 +2,8 @@
|
||||
|
||||
class BuildData {
|
||||
static const String name = "ServerBox";
|
||||
static const int build = 422;
|
||||
static const int build = 423;
|
||||
static const String engine = "3.10.6";
|
||||
static const String buildAt = "2023-08-05 17:05:26.027438";
|
||||
static const int modifications = 10;
|
||||
static const String buildAt = "2023-08-05 21:13:42.622817";
|
||||
static const int modifications = 7;
|
||||
}
|
||||
|
||||
@@ -266,7 +266,6 @@ class _DockerManagePageState extends State<DockerManagePage> {
|
||||
_buildImageHeader(),
|
||||
_buildImageItems(),
|
||||
_buildEditHost(),
|
||||
const SizedBox(height: 37),
|
||||
].map((e) => RoundRectCard(e));
|
||||
return ListView(
|
||||
padding: const EdgeInsets.all(7),
|
||||
|
||||
@@ -619,10 +619,16 @@ class _SftpPageState extends State<SftpPage> {
|
||||
_status.client = sftpc;
|
||||
}
|
||||
try {
|
||||
final fs =
|
||||
await _status.client!.listdir(path ?? _status.path?.path ?? '/');
|
||||
final listPath = path ?? _status.path?.path ?? '/';
|
||||
final fs = await _status.client!.listdir(listPath);
|
||||
fs.sort((a, b) => a.filename.compareTo(b.filename));
|
||||
fs.removeAt(0);
|
||||
|
||||
/// Issue #97
|
||||
/// In order to compatible with the Synology NAS
|
||||
/// which not has '.' and '..' in listdir
|
||||
if (fs.isNotEmpty && fs.first.filename == '.') {
|
||||
fs.removeAt(0);
|
||||
}
|
||||
if (mounted) {
|
||||
setState(() {
|
||||
_status.files = fs;
|
||||
|
||||
Reference in New Issue
Block a user