Skip to content

Commit

Permalink
fix: fix warning message when s:config() is found (fix #217)
Browse files Browse the repository at this point in the history
  • Loading branch information
tyru committed Apr 6, 2018
1 parent ffe0190 commit d8af4ed
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion plugconf/plugconf.go
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,9 @@ func ParsePlugconf(file *ast.File, src []byte, path string) (*ParsedInfo, *Parse
return true
}
parseErr.mwarn = multierror.Append(parseErr.mwarn,
errors.New("s:config() is deprecated. please use s:on_load_pre() instead"))
errors.New("s:config() is deprecated. "+
"please use s:on_load_pre() instead, or run "+
"\"volt migrate plugconf/config-func\" to rewrite existing plugconf files"))
if !isEmptyFunc(fn) {
onLoadPreFunc = string(extractBody(fn, src))
onLoadPreFunc = rxFuncName.ReplaceAllString(
Expand Down

0 comments on commit d8af4ed

Please sign in to comment.