export function formatUserName(
	fullName: string,
	previousFirstName?: string | null,
	previousLastName?: string | null
): string {
	if (previousFirstName && previousLastName) {
		return `${fullName} (formerly ${previousFirstName} ${previousLastName})`;
	}
	if (previousFirstName) {
		return `${fullName} (formerly ${previousFirstName})`;
	}
	if (previousLastName) {
		return `${fullName} (formerly ${previousLastName})`;
	}
	return fullName;
}
