Prefer index instead substring take '1'

This commit is contained in:
Ivandro Ismael 2016-02-25 06:38:53 +00:00
parent 17e7c898da
commit ebc59a2dd2

View File

@ -98,7 +98,7 @@ namespace Nikse.SubtitleEdit.Core.SubtitleFormats
string end = node.Attributes["end"].InnerText;
string text = node.InnerText;
if (allTwoCifferMs && (start.Length != 11 || end.Length != 11 || start.Substring(8, 1) != ":" || end.Substring(8, 1) != ":"))
if (allTwoCifferMs && (start.Length != 11 || end.Length != 11 || start[8] == ':' || end[8] == ':'))
{
allTwoCifferMs = false;
}