update frontend code