Project import generated by Copybara.

GitOrigin-RevId: 63746295f1a5ab5a619056791995793d65529e62
diff --git a/upgradescripts/3_peoplednibugfix.php b/upgradescripts/3_peoplednibugfix.php
new file mode 100644
index 0000000..975f57e
--- /dev/null
+++ b/upgradescripts/3_peoplednibugfix.php
@@ -0,0 +1,18 @@
+<?php
+// @description: Program used to upgrade the database to fix a bug which didn't let multiple users have an empty DNI.
+
+require_once(__DIR__."/../core.php");
+
+if (php_sapi_name() != "cli") {
+  security::notFound();
+  exit();
+}
+
+echo "=====================\n";
+echo "3_peoplednibugfix.php\n";
+echo "=====================\n\n";
+
+echo "[info] Removing unique index for field dni in table people...\n";
+if (!mysqli_query($con, "ALTER TABLE people DROP INDEX dni")) die("[fatal error] Couldn't delete index: ".mysqli_error($con)."\n");
+
+echo "[info] Done\n";