(SOLVED)Undefined error after trying to get values from a dictionary which does not exist

I have solved the problem already. I tried to get a value from a dictionary which I have created a variable for. After (accidentally) trying to set the variable to the dictionary by retrieving it from tinydb with a tag that DID NOT exist, TheValueIfNotThere of the tinydb had given the dictionary the value ( " " ). An undefined error occured. I just set the TheValueIfNotThere of the
tinydb tag to "create empty dictionary and solved it.