fix builds

This commit is contained in:
Aidan 2020-07-19 15:11:35 -07:00
parent ae9ca588d6
commit 26e331f331
No known key found for this signature in database
GPG key ID: 327711E983899316
4 changed files with 20 additions and 21 deletions

View file

@ -116,7 +116,7 @@ func Fexists(in *ast.Token, vt ast.VarTable, ft ast.FuncTable) *ast.Token {
*/
func Fread(in *ast.Token, vt ast.VarTable, ft ast.FuncTable) *ast.Token {
in = in.Eval(ft, vt, false)
exists := fexists(in, vt, ft) // some waste, extra use of Eval
exists := Fexists(in, vt, ft) // some waste, extra use of Eval
if exists == nil || exists.Tag != ast.BOOL || exists.Value() == ast.FALSE {
log.Log(log.ERR,
"error calling fexists or file doesnt exist",
@ -199,7 +199,7 @@ func Fappend(in *ast.Token, vt ast.VarTable, ft ast.FuncTable) *ast.Token {
return nil
}
exists := fexists(in, vt, ft)
exists := Fexists(in, vt, ft)
if exists.Value() == ast.FALSE {
log.Log(log.ERR,
"file "+in.Value()+" does not exist",