Ensure lbjs ending when saving substitutions to file