Moved render error functions to helpers