           l "HEY OK SEE NEXT 0.1"
         else if !databaseAccount?
           # No account found. Try to pull before recovering
+
           ledger.database.contexts.main.refresh().then ->
             pulled = yes
             createAccount()


  _updateLayout: (err, transaction, push, next) ->
    # Notify to the layout that the path is used
    needsNotify = no

    for path in _(transaction.inputs.concat(transaction.outputs)).chain().map((i) -> i.paths).flatten().compact().value()
      l "Notify used ", path
      needsNotify = ledger.wallet.Wallet.instance.getAccountFromDerivationPath(path).notifyPathsAsUsed([path]) or needsNotify

    @_notifyNewPathAreAvailable() if needsNotify # Clear and fetch the cache
    push null, transaction
    do next


  _extendTransaction: (err, transaction, push, next) ->
    wallet = ledger.wallet.Wallet.instance
    @_getAddressCache().then (cache) =>
      l "IN CACHE ", cache
      for io in transaction.inputs.concat(transaction.outputs)
        io.paths = []
        io.accounts = []
