update back-end code