Conservation laws for non-global Lagrangians