Skip to content

Commit b4555b3

Browse files
committed
fix: remove depecated function in exposed
1 parent cba8c58 commit b4555b3

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

server/src/main/kotlin/org/javacs/kt/index/SymbolIndex.kt

+4-4
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ class SymbolIndex(
9393

9494
init {
9595
transaction(db) {
96-
SchemaUtils.createMissingTablesAndColumns(Symbols, Locations, Ranges, Positions)
96+
SchemaUtils.create(Symbols, Locations, Ranges, Positions)
9797
}
9898
}
9999

@@ -111,7 +111,7 @@ class SymbolIndex(
111111
addDeclarations(allDescriptors(module, exclusions))
112112

113113
val finished = System.currentTimeMillis()
114-
val count = Symbols.selectAll().first()[Symbols.fqName.count()]
114+
val count = Symbols.select(Symbols.fqName.count()).first()[Symbols.fqName.count()]
115115
LOG.info("Updated full symbol index in ${finished - started} ms! (${count} symbol(s))")
116116
}
117117
} catch (e: Exception) {
@@ -134,7 +134,7 @@ class SymbolIndex(
134134
addDeclarations(add)
135135

136136
val finished = System.currentTimeMillis()
137-
val count = Symbols.selectAll().first()[Symbols.fqName.count()]
137+
val count = Symbols.select(Symbols.fqName.count()).first()[Symbols.fqName.count()]
138138
LOG.info("Updated symbol index in ${finished - started} ms! (${count} symbol(s))")
139139
}
140140
} catch (e: Exception) {
@@ -149,7 +149,7 @@ class SymbolIndex(
149149

150150
if (validFqName(descriptorFqn) && (extensionReceiverFqn?.let { validFqName(it) } != false)) {
151151
Symbols.deleteWhere {
152-
(Symbols.fqName eq descriptorFqn.toString()) and (Symbols.extensionReceiverType eq extensionReceiverFqn?.toString())
152+
(fqName eq descriptorFqn.toString()) and (extensionReceiverType eq extensionReceiverFqn?.toString())
153153
}
154154
} else {
155155
LOG.warn("Excluding symbol {} from index since its name is too long", descriptorFqn.toString())

shared/src/main/kotlin/org/javacs/kt/classpath/CachedClassPathResolver.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ internal class CachedClassPathResolver(
101101

102102
init {
103103
transaction(db) {
104-
SchemaUtils.createMissingTablesAndColumns(
104+
SchemaUtils.create(
105105
ClassPathMetadataCache, ClassPathCacheEntry, BuildScriptClassPathCacheEntry
106106
)
107107
}

shared/src/main/kotlin/org/javacs/kt/database/DatabaseService.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class DatabaseService {
3737
db = getDbFromFile(storagePath)
3838

3939
val currentVersion = transaction(db) {
40-
SchemaUtils.createMissingTablesAndColumns(DatabaseMetadata)
40+
SchemaUtils.create(DatabaseMetadata)
4141

4242
DatabaseMetadataEntity.all().firstOrNull()?.version ?: 0
4343
}

0 commit comments

Comments
 (0)