Skip to content

Commit

Permalink
everything is in ugly lowercase now
Browse files Browse the repository at this point in the history
  • Loading branch information
SnosMe committed Jul 26, 2023
1 parent 06ef398 commit 3bfb1ca
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
3 changes: 1 addition & 2 deletions viewer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,9 @@
"comlink": "^4.3.0",
"expiry-map": "^2.0.0",
"file-saver": "^2.0.2",
"fnv-plus": "^1.3.1",
"idb": "^7.0.0",
"ooz-wasm": "^1.0.0",
"pathofexile-dat": "^7.0.0",
"pathofexile-dat": "^8.0.0",
"pathofexile-dat-schema": "^3.0.0",
"pluralize": "^8.0.0",
"tailwindcss": "^3.0.0",
Expand Down
7 changes: 4 additions & 3 deletions viewer/src/app/dat-viewer/db.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ export class DatSchemasDatabase {
}

async preloadDataTables (totalTables: Ref<number>) {
const filePaths = this.index.getDirContent('Data')
const filePaths = this.index.getDirContent('data')
.files
.filter(file => file.endsWith('.dat64')) // this also removes special `Languages.dat`

Expand Down Expand Up @@ -114,7 +114,7 @@ export class DatSchemasDatabase {

const datFile = readDatFile(fullPath, res.slice)
const columnStats = await analyzeDatFile(datFile, { transfer: true })
const name = fullPath.replace('Data/', '').replace('.dat64', '')
const name = fullPath.replace('data/', '').replace('.dat64', '')

const serialized = await this.findByName(name)
const headers = fromSerializedHeaders(serialized, columnStats, datFile)
Expand Down Expand Up @@ -147,7 +147,8 @@ function serializeHeaders (headers: Header[]) {
}

function fromPublicSchema (name: string, publicSchema: SchemaFile['tables']): ViewerSerializedHeader[] | null {
const sch = publicSchema.find(s => s.name === name)
name = name.toLowerCase()
const sch = publicSchema.find(s => s.name.toLowerCase() === name)
if (!sch) return null

return sch.columns.map(column => {
Expand Down
2 changes: 1 addition & 1 deletion viewer/src/app/workbench/IndexTree.vue
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ export default defineComponent({
const searchExtension = shallowRef('.dat64')
const extensionOpts = computed(() => {
if (!currentDir.value.startsWith('Data')) return null
if (!currentDir.value.startsWith('data')) return null
return ['.dat', '.dat64', '.datl', '.datl64'].map(ext => ({
value: ext,
Expand Down

0 comments on commit 3bfb1ca

Please sign in to comment.