PLT-1909 Fixed error rendering pending posts (#3041)

* Fixed error caused by checking if a post is a system message

* Fixed trying to edit system posts when using the up arrow hotkey
Этот коммит содержится в:
Harrison Healey
2016-05-18 11:15:17 -04:00
коммит произвёл Christopher Speller
родитель d48be63513
Коммит 02576f3d59
4 изменённых файлов: 6 добавлений и 5 удалений

Просмотреть файл

@@ -85,7 +85,7 @@ export default class RhsComment extends React.Component {
const isOwner = this.props.currentUser.id === post.user_id;
var isAdmin = TeamStore.isTeamAdminForCurrentTeam() || UserStore.isSystemAdminForCurrentUser();
const isSystemMessage = post.type.startsWith(Constants.SYSTEM_MESSAGE_PREFIX);
const isSystemMessage = post.type && post.type.startsWith(Constants.SYSTEM_MESSAGE_PREFIX);
var dropdownContents = [];