           originId, type, unit
         }
 
-        reward.save (err) ->
-          return callback err  if err
-          queue.next()
-
-      ->
+        reward.save next
+
+      (next) ->
 
         campaign.increaseGivenAmount (err) ->
           logError "Couldn't increase given amount:", err  if err?
-
-          callback null
+          next()
 
     ]
 
-    daisy queue
+    async.series queue, (err) ->
+      return callback err  if err
+      callback null
 
 
   logError = (rest...) -> console.error '[Rewards]', rest...


      queue = [

        ->

          user.fetchOwnAccount (err, myAccount) ->
            return logError err  if err
            # if account not found then do nothing and return
            return logError "Account couldn't found" unless myAccount

            me = myAccount
            queue.next()

        ->

          if me.referralUsed
            return logError 'User already get the referrer'

          fetchReferrer me, (err, _referrer) ->
            return logError err  if err
            return  unless _referrer
            referrer = _referrer
            queue.next()

        ->

          me.update { $set: { 'referralUsed': yes } }, (err) ->
            return logError err if err
            queue.next()

        ->

          confirmRewards referrer, me, (err) ->
            return logError err if err
            queue.next()

        ->

          confirmRewards me, referrer, (err) ->
            return logError err if err
            queue.next()

      ]

      daisy queue


  do ->

                reward.providedBy = null
                reward._hasError  = new KodingError 'No user found'

              next()

        async.series queue, (err) ->
          callback null, { total, rewards }

  # Background Processes
  # --------------------
