moved from render to init method

This commit is contained in:
Tony Tam
2015-02-18 21:05:36 -08:00
parent 0afc64d6aa
commit c2c6c19179

View File

@@ -1,14 +1,14 @@
class ResourceView extends Backbone.View
initialize: (opts={}) ->
@auths = opts.auths
if "" is @model.description
if "" is @model.description
@model.description = null
if @model.description?
@model.summary = @model.description
render: ->
methods = {}
if @model.description?
@model.summary = @model.description
$(@el).html(Handlebars.templates.resource(@model))