diff src/luan/modules/lucene/PostgresBackup.java @ 1399:38a1c1b4279a

fix
author Franklin Schmidt <fschmidt@gmail.com>
date Wed, 11 Sep 2019 16:28:38 -0600
parents 67c0e47b5be3
children 27efb1fcbcb5
line wrap: on
line diff
--- a/src/luan/modules/lucene/PostgresBackup.java	Wed Sep 11 15:48:49 2019 -0600
+++ b/src/luan/modules/lucene/PostgresBackup.java	Wed Sep 11 16:28:38 2019 -0600
@@ -224,7 +224,8 @@
 		LuanTable getDoc(long id) throws SQLException, LuanException {
 			pstmt.setLong(1,id);
 			ResultSet rs = pstmt.executeQuery();
-			rs.next();
+			if( !rs.next() )
+				return null;
 			String data = rs.getString("data");
 			LuanTable doc = (LuanTable)eval(data,env);
 			return doc;