error public js