mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-17 07:00:12 +01:00
🎨 Trust plugins loading on mobile-end
This commit is contained in:
parent
57066c7dc9
commit
256e64e8b5
1 changed files with 8 additions and 1 deletions
|
|
@ -74,10 +74,17 @@ func SetPetalEnabled(name string, enabled bool, frontend string) (ret *Petal, er
|
||||||
func LoadPetals(frontend string) (ret []*Petal) {
|
func LoadPetals(frontend string) (ret []*Petal) {
|
||||||
ret = []*Petal{}
|
ret = []*Petal{}
|
||||||
|
|
||||||
if Conf.Bazaar.PetalDisabled || !Conf.Bazaar.Trust {
|
if Conf.Bazaar.PetalDisabled {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if !Conf.Bazaar.Trust {
|
||||||
|
// 移动端没有集市模块,所以要默认开启,桌面端和 Docker 容器需要用户手动确认过信任后才能开启
|
||||||
|
if util.ContainerStd == util.Container || util.ContainerDocker == util.Container {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
petals := getPetals()
|
petals := getPetals()
|
||||||
for _, petal := range petals {
|
for _, petal := range petals {
|
||||||
_, petal.DisplayName, petal.Incompatible = bazaar.ParseInstalledPlugin(petal.Name, frontend)
|
_, petal.DisplayName, petal.Incompatible = bazaar.ParseInstalledPlugin(petal.Name, frontend)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue