 
     newAsset: (modelData, href) ->
       @configSelectLists().done =>
-        asset = undefined
-        if modelData
+        asset = null
+        if modelData?        
           asset = new @assetModel(modelData)
         else
           asset = new @assetModel()


    setProject: (projectIdref) ->
      @projectIdref = projectIdref
      @refreshFieldSet projectIdref    
      #this.configureListPage();
      @_listLoaded = false

    loadRequests: (projectIdref) ->
      @_listLoaded = true
      if not projectIdref? or projectIdref is "undefined"
        projectIdref = @projectIdref
      else
        @setProject projectIdref

      options.headers = @headers  unless @serviceGateway
      return options

    createFetchModel: (url) ->
      options = {}
      options.headers = @headers unless @serviceGateway
      props = 
        url: url
        get: ->
          return @fetch(options)

      fetchModel = Backbone.Model.extend(props)

      return new fetchModel()

    createAsset: (assetName, callback) ->
      url = @getAssetUrl(assetName)
      @requestorName = $("#RequestedBy").val()
