Skip to content

Commit

Permalink
[change] block, component api
Browse files Browse the repository at this point in the history
  • Loading branch information
trheyi committed Sep 29, 2023
1 parent 1aade99 commit 3b8f1f3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions sui/api/process.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
package api

import (
"strings"

"github.com/yaoapp/gou/process"
"github.com/yaoapp/kun/exception"
"github.com/yaoapp/yao/sui/core"
Expand Down Expand Up @@ -105,7 +107,7 @@ func BlockFind(process *process.Process) interface{} {

sui := get(process)
templateID := process.ArgsString(1)
blockID := process.ArgsString(2)
blockID := strings.TrimRight(process.ArgsString(2), ".js")

tmpl, err := sui.GetTemplate(templateID)
if err != nil {
Expand Down Expand Up @@ -145,7 +147,7 @@ func ComponentFind(process *process.Process) interface{} {

sui := get(process)
templateID := process.ArgsString(1)
componentID := process.ArgsString(2)
componentID := strings.TrimRight(process.ArgsString(2), ".js")

tmpl, err := sui.GetTemplate(templateID)
if err != nil {
Expand Down

0 comments on commit 3b8f1f3

Please sign in to comment.