🤔 fixed weird stuff - still works tho 🤷

Signed-off-by: rapterjet2004 <juliuslinus1@gmail.com>
This commit is contained in:
rapterjet2004 2024-01-10 07:33:54 -06:00
parent 857d356615
commit dc3ca809ff
3 changed files with 277 additions and 138 deletions

View file

@ -0,0 +1,140 @@
{
"formatVersion": 1,
"database": {
"version": 9,
"identityHash": "250a3a56f3943f0d72f7ca0aac08fd1e",
"entities": [
{
"tableName": "User",
"createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `userId` TEXT, `username` TEXT, `baseUrl` TEXT, `token` TEXT, `displayName` TEXT, `pushConfigurationState` TEXT, `capabilities` TEXT, `clientCertificate` TEXT, `externalSignalingServer` TEXT, `current` INTEGER NOT NULL, `scheduledForDeletion` INTEGER NOT NULL)",
"fields": [
{
"fieldPath": "id",
"columnName": "id",
"affinity": "INTEGER",
"notNull": true
},
{
"fieldPath": "userId",
"columnName": "userId",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "username",
"columnName": "username",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "baseUrl",
"columnName": "baseUrl",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "token",
"columnName": "token",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "displayName",
"columnName": "displayName",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "pushConfigurationState",
"columnName": "pushConfigurationState",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "capabilities",
"columnName": "capabilities",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "clientCertificate",
"columnName": "clientCertificate",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "externalSignalingServer",
"columnName": "externalSignalingServer",
"affinity": "TEXT",
"notNull": false
},
{
"fieldPath": "current",
"columnName": "current",
"affinity": "INTEGER",
"notNull": true
},
{
"fieldPath": "scheduledForDeletion",
"columnName": "scheduledForDeletion",
"affinity": "INTEGER",
"notNull": true
}
],
"primaryKey": {
"autoGenerate": true,
"columnNames": [
"id"
]
},
"indices": [],
"foreignKeys": []
},
{
"tableName": "ArbitraryStorage",
"createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`accountIdentifier` INTEGER NOT NULL, `key` TEXT NOT NULL, `object` TEXT NOT NULL, `value` TEXT, PRIMARY KEY(`accountIdentifier`, `key`))",
"fields": [
{
"fieldPath": "accountIdentifier",
"columnName": "accountIdentifier",
"affinity": "INTEGER",
"notNull": true
},
{
"fieldPath": "key",
"columnName": "key",
"affinity": "TEXT",
"notNull": true
},
{
"fieldPath": "storageObject",
"columnName": "object",
"affinity": "TEXT",
"notNull": true
},
{
"fieldPath": "value",
"columnName": "value",
"affinity": "TEXT",
"notNull": false
}
],
"primaryKey": {
"autoGenerate": false,
"columnNames": [
"accountIdentifier",
"key",
"object"
]
},
"indices": [],
"foreignKeys": []
}
],
"views": [],
"setupQueries": [
"CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)",
"INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, '250a3a56f3943f0d72f7ca0aac08fd1e')"
]
}
}

View file

@ -2,7 +2,7 @@
"formatVersion": 1, "formatVersion": 1,
"database": { "database": {
"version": 9, "version": 9,
"identityHash": "250a3a56f3943f0d72f7ca0aac08fd1e", "identityHash": "666fcc4bbbdf3ff121b8f1ace8fcbcb8",
"entities": [ "entities": [
{ {
"tableName": "User", "tableName": "User",
@ -92,7 +92,7 @@
}, },
{ {
"tableName": "ArbitraryStorage", "tableName": "ArbitraryStorage",
"createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`accountIdentifier` INTEGER NOT NULL, `key` TEXT NOT NULL, `object` TEXT NOT NULL, `value` TEXT, PRIMARY KEY(`accountIdentifier`, `key`))", "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`accountIdentifier` INTEGER NOT NULL, `key` TEXT NOT NULL, `object` TEXT, `value` TEXT, PRIMARY KEY(`accountIdentifier`, `key`))",
"fields": [ "fields": [
{ {
"fieldPath": "accountIdentifier", "fieldPath": "accountIdentifier",
@ -110,7 +110,7 @@
"fieldPath": "storageObject", "fieldPath": "storageObject",
"columnName": "object", "columnName": "object",
"affinity": "TEXT", "affinity": "TEXT",
"notNull": true "notNull": false
}, },
{ {
"fieldPath": "value", "fieldPath": "value",
@ -123,8 +123,7 @@
"autoGenerate": false, "autoGenerate": false,
"columnNames": [ "columnNames": [
"accountIdentifier", "accountIdentifier",
"key", "key"
"object"
] ]
}, },
"indices": [], "indices": [],
@ -134,7 +133,7 @@
"views": [], "views": [],
"setupQueries": [ "setupQueries": [
"CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)", "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)",
"INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, '250a3a56f3943f0d72f7ca0aac08fd1e')" "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, '666fcc4bbbdf3ff121b8f1ace8fcbcb8')"
] ]
} }
} }

View file

@ -136,9 +136,9 @@ object Migrations {
db.execSQL( db.execSQL(
"CREATE TABLE ArbitraryStorage_triplePK (" + "CREATE TABLE ArbitraryStorage_triplePK (" +
"accountIdentifier INTEGER NOT NULL, " + "accountIdentifier INTEGER NOT NULL, " +
"value TEXT, " +
"\"key\" TEXT NOT NULL, " + "\"key\" TEXT NOT NULL, " +
"object TEXT NOT NULL, " + "object TEXT NOT NULL, " +
"value TEXT, " +
"PRIMARY KEY(accountIdentifier, \"key\", object)" + "PRIMARY KEY(accountIdentifier, \"key\", object)" +
")" ")"
) )