How to use the lockr.rm function in lockr

To help you get started, we’ve selected a few lockr examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github tronscan / tronscan-frontend / src / reducers / app.js View on Github external
address: action.address,
          isOpen: true,
        },
      };
    }

    case LOGOUT: {
      Lockr.rm("account_key");
      Lockr.rm("account_address");
      Lockr.set("islogin", 0);
      //  compileCode
      Lockr.rm('CompileCode');
      // compile status
      Lockr.rm('CompileStatus');
      // contractNameList
      Lockr.rm('contractNameList');
      // compileInfo
      Lockr.rm('compileInfo');
      // compile files
      Lockr.rm('compileFiles');
      return {
        ...state,
        account: {
          key: undefined,
          isLoggedIn: false,
        },
        wallet: {
          type: undefined,
          address: undefined,
          isOpen: false,
        },
      }
github tronscan / tronscan-frontend / src / reducers / app.js View on Github external
tronStationSDK: new TronStationSDK(action.tronWeb, true)
        },
        wallet: {
          type: ACCOUNT_LEDGER,
          address: action.address,
          isOpen: true,
        },
      };
    }

    case LOGOUT: {
      Lockr.rm("account_key");
      Lockr.rm("account_address");
      Lockr.set("islogin", 0);
      //  compileCode
      Lockr.rm('CompileCode');
      // compile status
      Lockr.rm('CompileStatus');
      // contractNameList
      Lockr.rm('contractNameList');
      // compileInfo
      Lockr.rm('compileInfo');
      // compile files
      Lockr.rm('compileFiles');
      return {
        ...state,
        account: {
          key: undefined,
          isLoggedIn: false,
        },
        wallet: {
          type: undefined,
github tronscan / tronscan-frontend / src / reducers / app.js View on Github external
}

    case LOGOUT: {
      Lockr.rm("account_key");
      Lockr.rm("account_address");
      Lockr.set("islogin", 0);
      //  compileCode
      Lockr.rm('CompileCode');
      // compile status
      Lockr.rm('CompileStatus');
      // contractNameList
      Lockr.rm('contractNameList');
      // compileInfo
      Lockr.rm('compileInfo');
      // compile files
      Lockr.rm('compileFiles');
      return {
        ...state,
        account: {
          key: undefined,
          isLoggedIn: false,
        },
        wallet: {
          type: undefined,
          address: undefined,
          isOpen: false,
        },
      }
    }

    case SET_THEME: {
      //Lockr.set("theme", action.theme);
github tronscan / tronscan-frontend / src / reducers / app.js View on Github external
wallet: {
          type: ACCOUNT_LEDGER,
          address: action.address,
          isOpen: true,
        },
      };
    }

    case LOGOUT: {
      Lockr.rm("account_key");
      Lockr.rm("account_address");
      Lockr.set("islogin", 0);
      //  compileCode
      Lockr.rm('CompileCode');
      // compile status
      Lockr.rm('CompileStatus');
      // contractNameList
      Lockr.rm('contractNameList');
      // compileInfo
      Lockr.rm('compileInfo');
      // compile files
      Lockr.rm('compileFiles');
      return {
        ...state,
        account: {
          key: undefined,
          isLoggedIn: false,
        },
        wallet: {
          type: undefined,
          address: undefined,
          isOpen: false,
github tronscan / tronscan-frontend / src / reducers / app.js View on Github external
address: action.address,
          tronWeb:action.tronWeb,
          sunWeb:action.sunWeb,
          tronStationSDK: new TronStationSDK(action.tronWeb, true)
        },
        wallet: {
          type: ACCOUNT_LEDGER,
          address: action.address,
          isOpen: true,
        },
      };
    }

    case LOGOUT: {
      Lockr.rm("account_key");
      Lockr.rm("account_address");
      Lockr.set("islogin", 0);
      //  compileCode
      Lockr.rm('CompileCode');
      // compile status
      Lockr.rm('CompileStatus');
      // contractNameList
      Lockr.rm('contractNameList');
      // compileInfo
      Lockr.rm('compileInfo');
      // compile files
      Lockr.rm('compileFiles');
      return {
        ...state,
        account: {
          key: undefined,
          isLoggedIn: false,
github segmentstream / digital-data-manager / src / Storage.js View on Github external
get (key) {
    key = this.getOption('prefix') + key

    if (!window.localStorage) { // SRP violation, but its ok for this case
      // TODO add logging;
      return undefined
    }
    const info = store.get(key)

    if (info instanceof Object) {
      if (info.val !== undefined && info.exp && info.time) {
        if ((Date.now() - info.time) > info.exp) {
          store.rm(key)
          return undefined
        }
        return info.val
      }
    }
    return info
  }
github tronscan / tronscan-frontend / src / reducers / app.js View on Github external
key: false,
          isLoggedIn: true,
          address: action.address
        },
        wallet: {
          type: ACCOUNT_ADDRESS,
          address: action.address,
          isOpen: true,
        },
      };
    }

    case LOGIN_TRONLINK:{

      if (IS_DESKTOP) {
        Lockr.rm("account_key");
        // Lockr.set("account_address", action.address);
      }
      return {
        ...state,
        account: {
          key: false,
          isLoggedIn: true,
          address: action.address,
          tronWeb:action.tronWeb,
          sunWeb:action.sunWeb,
          tronStationSDK: IS_MAINNET? new TronStationSDK(action.tronWeb,true): new TronStationSDK(action.sunWeb.sidechain,true),
        },
        wallet: {
          type: ACCOUNT_TRONLINK,
          address: action.address,
          isOpen: true,
github tronscan / tronscan-frontend / src / components / blockchain / Compiler / index.js View on Github external
componentDidMount() {

        let { match } = this.props;
        if (match.params && match.params.type === 'verify'){
            this.setState({
                filter: { direction: 'verify' }
            });
        } else {
            // 初始化数据
            if (!this.isLoggedIn(1)){
                //  compileCode
                Lockr.rm('CompileCode');
                // compile status
                Lockr.rm('CompileStatus');
                // contractNameList
                Lockr.rm('contractNameList');
                // compileInfo
                Lockr.rm('compileInfo');
                // compile files
                Lockr.rm('compileFiles');
                return;
            }


            this.initCompile();
        }
    }
github segmentstream / digital-data-manager / src / Storage.js View on Github external
remove (key) {
    key = this.getOption('prefix') + key
    return store.rm(key)
  }

lockr

![Lockr logo](http://i.imgur.com/m5kPjkB.png)

MIT
Latest version published 2 years ago

Package Health Score

51 / 100
Full package analysis