But when I'm doing the !lean command, the bot just says "TCL Error: can't read $fs, no such variabel" Anyone got a clue here? i can't find anything wrong hehe

The proc looks like this:
proc egginfo:add {nick uh handle chan text} {
global egginfo
if {[egginfo:checkaccess $handle flags] == 2} {
putserv "$egginfo(changes) $nick :Sorry mate, You don't hace access"
return 0
}
set word [string tolower [lindex $text 0]]
set def [lrange $text 1 end]
if {$def == ""} {
putserv "$egginfo(changes) $nick :Somethings wrong, Syntax: use $egginfo(add) <word> <defenition>"
return 0
}
set $fs [open $egginfo(file) a]
puts $fs "$word $def"
close $fs
putserv "$egginfo(changes) $nick :I have added $word to the database"
}