More backend code tweaks