Opened 13 years ago

Closed 13 years ago

#31 closed defect (fixed)

replace() method returns void

Reported by: ajh Owned by: gogo
Priority: normal Milestone:
Component: Xinha Core Version:
Severity: normal Keywords:
Cc:

Description

The replace method is coded so that it returns the return value of the generate method (which is always void). It should probably be recoded so that it returns the actual HTMLArea object:

HTMLArea.replace = function(id, config) {
  var ta = HTMLArea.getElementById("textarea", id);
  if (ta) {
  	var taobj = new HTMLArea(ta, config);
  	taobj.generate();
  	return taobj;
  }
  else
  {
    return null;
  };
};

There's probably a better way of coding this, but this is the idea.

Change History (1)

comment:1 Changed 13 years ago by gogo

  • Resolution set to fixed
  • Status changed from new to closed

That looks fine, applied in changeset:31

Note: See TracTickets for help on using tickets.