fixing apphb error 500