@capgo/cli 4.0.13 → 4.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [4.0.14](https://github.com/Cap-go/CLI/compare/v4.0.13...v4.0.14) (2024-02-27)
6
+
5
7
  ### [4.0.13](https://github.com/Cap-go/CLI/compare/v4.0.12...v4.0.13) (2024-02-26)
6
8
 
7
9
 
package/dist/index.js CHANGED
@@ -61137,7 +61137,7 @@ var {
61137
61137
  // package.json
61138
61138
  var package_default = {
61139
61139
  name: "@capgo/cli",
61140
- version: "4.0.13",
61140
+ version: "4.0.14",
61141
61141
  description: "A CLI to upload to capgo servers",
61142
61142
  main: "dist/index.js",
61143
61143
  bin: {
@@ -62930,17 +62930,17 @@ async function checkAppExists(supabase, appid) {
62930
62930
  return !!app2;
62931
62931
  }
62932
62932
  async function checkAppExistsAndHasPermissionErr(supabase, apikey, appid, shouldExist = true) {
62933
- const res = await checkAppExists(supabase, appid);
62933
+ const appExist = await checkAppExists(supabase, appid);
62934
62934
  const perm = await isAllowedApp(supabase, apikey, appid);
62935
- if (res && !shouldExist) {
62935
+ if (appExist && !shouldExist) {
62936
62936
  f2.error(`App ${appid} already exist`);
62937
62937
  program.error("");
62938
62938
  }
62939
- if (!res && shouldExist) {
62939
+ if (!appExist && shouldExist) {
62940
62940
  f2.error(`App ${appid} does not exist`);
62941
62941
  program.error("");
62942
62942
  }
62943
- if (res && !perm) {
62943
+ if (appExist && !perm) {
62944
62944
  f2.error(`App ${appid} exist and you don't have permission to access it`);
62945
62945
  if (appid === "io.ionic.starter")
62946
62946
  f2.info("Modify your appid in your capacitor.config.json file to something unique, this is a default appid for ionic starter app");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@capgo/cli",
3
- "version": "4.0.13",
3
+ "version": "4.0.14",
4
4
  "description": "A CLI to upload to capgo servers",
5
5
  "main": "dist/index.js",
6
6
  "bin": {
package/src/api/app.ts CHANGED
@@ -13,18 +13,18 @@ export async function checkAppExists(supabase: SupabaseClient<Database>, appid:
13
13
  }
14
14
 
15
15
  export async function checkAppExistsAndHasPermissionErr(supabase: SupabaseClient<Database>, apikey: string, appid: string, shouldExist = true) {
16
- const res = await checkAppExists(supabase, appid)
16
+ const appExist = await checkAppExists(supabase, appid)
17
17
  const perm = await isAllowedApp(supabase, apikey, appid)
18
18
 
19
- if (res && !shouldExist) {
19
+ if (appExist && !shouldExist) {
20
20
  p.log.error(`App ${appid} already exist`)
21
21
  program.error('')
22
22
  }
23
- if (!res && shouldExist) {
23
+ if (!appExist && shouldExist) {
24
24
  p.log.error(`App ${appid} does not exist`)
25
25
  program.error('')
26
26
  }
27
- if (res && !perm) {
27
+ if (appExist && !perm) {
28
28
  p.log.error(`App ${appid} exist and you don't have permission to access it`)
29
29
  if (appid === 'io.ionic.starter')
30
30
  p.log.info('Modify your appid in your capacitor.config.json file to something unique, this is a default appid for ionic starter app')