Fix bad accesses and bad arguments

Attention: `/tokeninfo` is still broken. Don't figure out how to fix it yet.