Skip to content

Commit 03be73e

Browse files
authored
Merge pull request #111 from KingCosmic/dev
fixed some build issues
2 parents fa5b2bb + 1c8b8be commit 03be73e

5 files changed

Lines changed: 4 additions & 38 deletions

File tree

.github/workflows/build-tauri.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848
# You can remove the one that doesn't apply to your app to speed up the workflow a bit.
4949

5050
- name: install frontend dependencies
51-
run: yarn install # change this to npm, pnpm or bun depending on which one you use.
51+
run: npm install # change this to npm, pnpm or bun depending on which one you use.
5252

5353
- uses: tauri-apps/tauri-action@v0
5454
env:

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Generate a build, publish and push to another branch.
22
on:
33
push:
44
branches:
5-
- master # The branch name to build deployments from.
5+
- main # The branch name to build deployments from.
66

77
jobs:
88
build:

package-lock.json

Lines changed: 1 addition & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
"screenshots": "node screenshots/grabScreenshots.js"
1414
},
1515
"dependencies": {
16-
"@capacitor/device": "^7.0.1",
1716
"@craftjs/core": "^0.2.11",
1817
"@floating-ui/react": "^0.27.8",
1918
"@ionic/storage": "^4.0.0",

src/utils/getDeviceName.ts

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import { Device } from '@capacitor/device'
2-
31
function getWebDeviceName() {
42
const ua = navigator.userAgent;
53
const platform = navigator.platform;
@@ -8,18 +6,6 @@ function getWebDeviceName() {
86
return `Web-${platform}-${lang}-${ua.slice(0, 15)}`; // trim UA to avoid huge string
97
}
108

11-
async function getDeviceName() {
12-
const info = await Device.getInfo();
13-
const deviceName = `${info.manufacturer || 'Unknown'} ${info.model || 'Device'}`;
14-
return deviceName;
15-
}
16-
179
export async function getDeviceIdentifier() {
18-
// Check if running in a Capacitor environment
19-
// @ts-ignore
20-
if (window.Capacitor && window.Capacitor.isNativePlatform) {
21-
return await getDeviceName();
22-
} else {
23-
return getWebDeviceName();
24-
}
10+
return getWebDeviceName()
2511
}

0 commit comments

Comments
 (0)