fixed mistake in processing order