From 15aa853da5f6be8a95970d73a700afc6b626c572 Mon Sep 17 00:00:00 2001
From: hmhealey <harrisonmhealey@gmail.com>
Date: Mon, 14 Sep 2015 11:48:07 -0400
Subject: Removed all calls to textToJsx and replaced them with calls to
 TextFormatting

---
 web/react/components/message_wrapper.jsx | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

(limited to 'web/react/components/message_wrapper.jsx')

diff --git a/web/react/components/message_wrapper.jsx b/web/react/components/message_wrapper.jsx
index bce305853..5adf4f228 100644
--- a/web/react/components/message_wrapper.jsx
+++ b/web/react/components/message_wrapper.jsx
@@ -1,7 +1,7 @@
 // Copyright (c) 2015 Spinpunch, Inc. All Rights Reserved.
 // See License.txt for license information.
 
-var Utils = require('../utils/utils.jsx');
+var TextFormatting = require('../utils/text_formatting.jsx');
 
 export default class MessageWrapper extends React.Component {
     constructor(props) {
@@ -10,10 +10,7 @@ export default class MessageWrapper extends React.Component {
     }
     render() {
         if (this.props.message) {
-            var inner = Utils.textToJsx(this.props.message, this.props.options);
-            return (
-                <div>{inner}</div>
-            );
+            return <div dangerouslySetInnerHTML={{__html: TextFormatting.formatText(this.props.message, this.props.options)}}/>;
         }
 
         return <div/>;
@@ -21,8 +18,7 @@ export default class MessageWrapper extends React.Component {
 }
 
 MessageWrapper.defaultProps = {
-    message: null,
-    options: null
+    message: ''
 };
 MessageWrapper.propTypes = {
     message: React.PropTypes.string,
-- 
cgit v1.2.3-1-g7c22

