adding helpful comments to error functions