Thanks to visit codestin.com
Credit goes to github.com

Skip to content

chore: comment original source for the code change on path expansion #161

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions init.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ func init() {
},
Type: function.StaticReturnType(cty.String),
Impl: func(args []cty.Value, retType cty.Type) (cty.Value, error) {
// This code is taken directly from https://github.com/mitchellh/go-homedir/blob/af06845cf3004701891bf4fdb884bfe4920b3727/homedir.go#L58
// The only change is that instead of expanding the path, we return an error
path := args[0].AsString()
if len(path) == 0 {
return cty.StringVal(path), nil
Expand Down
Loading