Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
perxis-go
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Package registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
perxis
perxis-go
Commits
4520c8be
Commit
4520c8be
authored
1 month ago
by
Semyon Krestyaninov
Browse files
Options
Downloads
Patches
Plain Diff
fix error message
parent
db3e9872
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
pkg/items/item.go
+1
-1
1 addition, 1 deletion
pkg/items/item.go
with
1 addition
and
1 deletion
pkg/items/item.go
+
1
−
1
View file @
4520c8be
...
@@ -243,7 +243,7 @@ func ToMap(item *Item, sch *schema.Schema) (map[string]any, error) {
...
@@ -243,7 +243,7 @@ func ToMap(item *Item, sch *schema.Schema) (map[string]any, error) {
// Вычисляемые поля игнорируются при декодировании.
// Вычисляемые поля игнорируются при декодировании.
func
FromMap
(
input
map
[
string
]
any
,
sch
*
schema
.
Schema
)
(
*
Item
,
error
)
{
func
FromMap
(
input
map
[
string
]
any
,
sch
*
schema
.
Schema
)
(
*
Item
,
error
)
{
if
len
(
input
)
==
0
{
if
len
(
input
)
==
0
{
return
nil
,
errors
.
New
(
"input map must not be nil"
)
return
nil
,
errors
.
New
(
"input map must not be
empty or
nil"
)
}
}
if
sch
==
nil
{
if
sch
==
nil
{
return
nil
,
errors
.
New
(
"schema must not be nil"
)
return
nil
,
errors
.
New
(
"schema must not be nil"
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment