 
       pendingPromise
       .then (id) =>
-        logger.info('pending id', id)
+        kryptnosticObject = KryptnosticObject.createFromDecrypted({id, body})
+        validateDecrypted(kryptnosticObject)
 
-        kryptnosticObject = KryptnosticObject.createFromDecrypted({id, body})
-
-        if kryptnosticObject.isEncrypted()
-          throw new Error('expected object to be in a decrypted state')
-
-        logger.info('object', kryptnosticObject)
-
-        cryptoServiceLoader = new CryptoServiceLoader()
-
-        logger.info('made crypto service loader')
-
-        cryptoServiceLoader.getObjectCryptoService(id, {expectMiss: true})
+        @cryptoServiceLoader.getObjectCryptoService(id, {expectMiss: true})
         .then (cryptoService) =>
-          encryptedObject = kryptnosticObject.encrypt(cryptoService)
-          logger.info('encrypted object', encryptedObject)
-          @submitObjectBlocks(encryptedObject)
+          encrypted = kryptnosticObject.encrypt(cryptoService)
+          @submitObjectBlocks(encrypted)
         .then ->
           return id
 


  logger = Logger.get('StorageClient')

  #
  # Client for listing and loading Kryptnostic encrypted objects.
  # Author: rbuckheit

  class StorageClient

    constructor : ->
      @objectApi           = new ObjectApi()
      @cryptoServiceLoader = new CryptoServiceLoader()

    getObjectIds : ->
      return @objectApi.getObjectIds()
