Fixed an error in toChar, the char* was not null terminated
The exists function didnt have a return, which will return garbage