Skip to content
Snippets Groups Projects
Commit bfa741d1 authored by Jared Hancock's avatar Jared Hancock
Browse files

oops: Add ::asVar to generic ThreadBody class

parent adc9df8b
No related branches found
No related tags found
No related merge requests found
......@@ -1377,6 +1377,11 @@ class ThreadBody /* extends SplString */ {
return $this->display('html');
}
function asVar() {
// Email template, assume HTML
return $this->display('email');
}
function display($format=false) {
throw new Exception('display: Abstract display() method not implemented');
}
......@@ -1421,11 +1426,6 @@ class TextThreadBody extends ThreadBody {
return '<pre>'.$this->body.'</pre>';
}
}
function asVar() {
// Email template, assume HTML
return $this->display('email');
}
}
class HtmlThreadBody extends ThreadBody {
function __construct($body, $options=array()) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment