Skip to content

Commit c997956

Browse files
authored
Merge pull request #48 from opentext/mohammadsuha/OTAG-14692-fix-any-issue
otag 14692 fix any issue
2 parents 4c689a3 + de41fcd commit c997956

14 files changed

+32
-32
lines changed

dist/appworks.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/appworks.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/appworks.min.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/appworks.min.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/plugins/storage/cache.d.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ export declare class AWCache extends AWPlugin {
44
private excludedKeys;
55
constructor(options?: any);
66
setExcludedKeys(_excludedKeys: string[]): void;
7-
setItem(key: string, value: any): Promise<any>;
7+
setItem(key: string, value: any): Promise<void>;
88
getItem(key: string): any;
9-
removeItem(key: string): Promise<any>;
10-
clear(): Promise<any>;
11-
preloadCache(): Promise<any>;
9+
removeItem(key: string): Promise<void>;
10+
clear(): Promise<void>;
11+
preloadCache(): Promise<void>;
1212
migrateCache(excludedKeys: string[]): Promise<any>;
1313
private usePersistentStorage();
1414
}

src/plugins/storage/cache.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/plugins/storage/cache.ts

+8-8
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ export class AWCache extends AWPlugin {
1717
this.excludedKeys = _excludedKeys;
1818
}
1919

20-
setItem(key: string, value: any): Promise<any> {
21-
return new Promise((resolve, reject) => {
20+
setItem(key: string, value: any): Promise<void> {
21+
return new Promise<void>((resolve, reject) => {
2222
AWProxy.storage().setItem(key, value);
2323
if (this.usePersistentStorage()) {
2424
AWProxy.persistentStorage().persistLocalStorage(this.excludedKeys)
@@ -34,8 +34,8 @@ export class AWCache extends AWPlugin {
3434
return (typeof item === 'undefined' ? '' : item);
3535
}
3636

37-
removeItem(key: string): Promise<any> {
38-
return new Promise((resolve, reject) => {
37+
removeItem(key: string): Promise<void> {
38+
return new Promise<void>((resolve, reject) => {
3939
AWProxy.storage().removeItem(key);
4040
if (this.usePersistentStorage()) {
4141
AWProxy.persistentStorage().persistLocalStorage(this.excludedKeys)
@@ -46,8 +46,8 @@ export class AWCache extends AWPlugin {
4646
});
4747
}
4848

49-
clear(): Promise<any> {
50-
return new Promise((resolve, reject) => {
49+
clear(): Promise<void> {
50+
return new Promise<void>((resolve, reject) => {
5151
AWProxy.storage().clear();
5252
if (this.usePersistentStorage()) {
5353
AWProxy.persistentStorage().persistLocalStorage(this.excludedKeys)
@@ -58,8 +58,8 @@ export class AWCache extends AWPlugin {
5858
});
5959
}
6060

61-
preloadCache(): Promise<any> {
62-
return new Promise((resolve, reject) => {
61+
preloadCache(): Promise<void> {
62+
return new Promise<void>((resolve, reject) => {
6363
if (this.usePersistentStorage()) {
6464
this.migrateCache(this.excludedKeys).then(() => {
6565
AWProxy.persistentStorage().loadPersistentData()

src/plugins/storage/desktop-storage.d.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ export declare class DesktopStorage implements PersistentStorage {
44
private desktopStorage;
55
constructor(desktopPlugin: AsyncStorage);
66
persistLocalStorage(excludedKeys: string[]): Promise<any>;
7-
loadPersistentData(): Promise<any>;
8-
migrateCache(excludedKeys: string[]): Promise<any>;
7+
loadPersistentData(): Promise<void>;
8+
migrateCache(excludedKeys: string[]): Promise<void>;
99
}

src/plugins/storage/desktop-storage.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/plugins/storage/desktop-storage.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/plugins/storage/desktop-storage.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,11 @@ export class DesktopStorage implements PersistentStorage {
3535
});
3636
}
3737

38-
loadPersistentData(): Promise<any> {
38+
loadPersistentData(): Promise<void> {
3939
if (this.desktopStorage === null) {
4040
return Promise.reject(DesktopStorage.PLUGIN_NOT_FOUND);
4141
}
42-
return new Promise((resolve, reject) => {
42+
return new Promise<void>((resolve, reject) => {
4343
try {
4444
// get data is actually synchronous
4545
const data = this.desktopStorage.getData();
@@ -56,11 +56,11 @@ export class DesktopStorage implements PersistentStorage {
5656
});
5757
}
5858

59-
migrateCache(excludedKeys: string[]): Promise<any> {
59+
migrateCache(excludedKeys: string[]): Promise<void> {
6060
if (this.desktopStorage === null) {
6161
return Promise.reject(DesktopStorage.PLUGIN_NOT_FOUND);
6262
}
6363

64-
return Promise.resolve();
64+
return Promise.resolve(null);
6565
}
6666
}

src/plugins/storage/on-device-storage.d.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ import { PersistentStorage } from './index';
44
*/
55
export declare class OnDeviceStorage implements PersistentStorage {
66
persistLocalStorage(excludedKeys: string[]): Promise<any>;
7-
loadPersistentData(): Promise<any>;
8-
migrateCache(excludedKeys: string[]): Promise<any>;
7+
loadPersistentData(): Promise<void>;
8+
migrateCache(excludedKeys: string[]): Promise<void>;
99
private readDataAWCacheFile();
1010
private deleteAWCacheFile();
1111
private readDataFromPersistentStorage();

0 commit comments

Comments
 (0)