redoing front-end processing code