mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
Fix url index bug with renaming.
This commit is contained in:
parent
ad7c7a4ba5
commit
4561409450
2 changed files with 2 additions and 2 deletions
|
@ -11,7 +11,7 @@ import java.sql.SQLException;
|
|||
public class CreateIndexURLIndexStore implements SQLUpdate {
|
||||
|
||||
public static final String CREATE_INDEX_URL_INDEX_STORE =
|
||||
"CREATE INDEX IF NOT EXISTS `project_path_index` ON `url_index_store`(`project_name`, `path`);\n";
|
||||
"CREATE UNIQUE INDEX IF NOT EXISTS `project_path_index` ON `url_index_store`(`project_name`, `path`);\n";
|
||||
|
||||
@Override
|
||||
public String getSQL() {
|
||||
|
|
|
@ -11,7 +11,7 @@ import java.sql.SQLException;
|
|||
public class AddURLIndexSQLUpdate implements SQLUpdate {
|
||||
|
||||
private static final String ADD_URL_INDEX =
|
||||
"INSERT INTO `url_index_store` (`project_name`, `url`, `path`) VALUES (?, ?, ?);\n";
|
||||
"INSERT OR REPLACE INTO `url_index_store` (`project_name`, `url`, `path`) VALUES (?, ?, ?);\n";
|
||||
|
||||
private final String projectName;
|
||||
private final String url;
|
||||
|
|
Loading…
Reference in a new issue