Modified a little for beautification