mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 07:00:12 +01:00
🎨 Improve marketplace loading performance https://github.com/siyuan-note/siyuan/issues/10973 https://github.com/siyuan-note/siyuan/issues/11007
This commit is contained in:
parent
16c665bfa7
commit
afeea6a80e
7 changed files with 42 additions and 61 deletions
|
|
@ -17,7 +17,6 @@
|
|||
package bazaar
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"sort"
|
||||
|
|
@ -26,7 +25,6 @@ import (
|
|||
|
||||
"github.com/dustin/go-humanize"
|
||||
ants "github.com/panjf2000/ants/v2"
|
||||
"github.com/siyuan-note/filelock"
|
||||
"github.com/siyuan-note/httpclient"
|
||||
"github.com/siyuan-note/logging"
|
||||
"github.com/siyuan-note/siyuan/kernel/util"
|
||||
|
|
@ -180,14 +178,9 @@ func InstallWidget(repoURL, repoHash, installPath string, systemID string) error
|
|||
if nil != err {
|
||||
return err
|
||||
}
|
||||
return installPackage(data, installPath)
|
||||
return installPackage(data, installPath, repoURLHash)
|
||||
}
|
||||
|
||||
func UninstallWidget(installPath string) error {
|
||||
if err := filelock.Remove(installPath); nil != err {
|
||||
logging.LogErrorf("remove widget [%s] failed: %s", installPath, err)
|
||||
return errors.New("remove community widget failed")
|
||||
}
|
||||
//logging.Logger.Infof("uninstalled widget [%s]", installPath)
|
||||
return nil
|
||||
return uninstallPackage(installPath)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue