diff --git a/scripts/port_from_sqlite_to_postgres.py b/scripts/port_from_sqlite_to_postgres.py
index 1e7ac072f1d3973b907e9a938aeffdffdea89c8a..56e149c477239a5887155c60f95f405f1f532c6e 100644
--- a/scripts/port_from_sqlite_to_postgres.py
+++ b/scripts/port_from_sqlite_to_postgres.py
@@ -575,7 +575,7 @@ class CursesProgress(Progress):
 
         if self.finished:
             self.stdscr.addstr(
-                self.rows-1, 0,
+                rows-1, 0,
                 "Press any key to exit...",
             )