     log.info 'Blog unique photos:', posts.length, '\n'
     log.info 'Duplicates:', total-posts.length, '\n'
 
-    # Plain old JSON, should/can be optimized a bit..
     # We remove 'nbNewPosts' as it is going to change and not relevant to store.
     delete blog.nbNewPosts
+
+    # We store the 'database' as a plain old JSON, should/can be optimized a bit probably..
     outputData = JSON.stringify blog
 
     # Write "database" to outputdir/.tumblrip

fs = require 'fs'
path = require 'path'
request = require 'request'
util = require 'util'
Q = require 'q'
mkdirp = require 'mkdirp'
URL = require 'url'
bhttp = require 'bhttp'

{ApiError, RejectError} = require './eh'
{log, pick, findInSubArray} = require './utils'
options = require './options'
{allDone, promiseRetry} = require './promise-helpers'

# Some common redefinitions
readFile = Q.nfbind fs.readFile
writeFile = Q.nfbind fs.writeFile
statFile = Q.nfbind fs.stat

get = (uri, method='GET') ->
  opts =
    uri: uri
    method: method

  process = (start, init=false) ->
    log.debug "Processing at #{start}...\n"
    # Get first round separately to know how many posts we will need to retrieve.
    api "#{url}?type=photo&num=50&start=#{start}"
    .then (parsed) ->
      # If we have a total number of posts and we are in the first loop, we are going to update..
      {total} = self
