{"action":"created","comment":{"url":"https://api.github.com/repos/google/shaka-player/pulls/comments/61719750","id":61719750,"diff_hunk":"@@ -160,6 +160,11 @@ shaka.media.TextEngine.prototype.appendBuffer =\n shaka.media.TextEngine.prototype.remove = function(start, end) {\n   // Start the operation asynchronously to avoid blocking the caller.\n   return Promise.resolve().then(function() {\n+    if (!this.track_.cues) {\n+      // This TextTrack was disabled before we started work. When TextTracks\n+      // move to disabled state their cues property is set to null\n+      return","path":"lib/media/text_engine.js","position":7,"original_position":7,"commit_id":"60443702c92bd38837d86617fcc1d069837b3e6b","original_commit_id":"60443702c92bd38837d86617fcc1d069837b3e6b","user":{"login":"joeyparrish","id":6843156,"avatar_url":"https://avatars.githubusercontent.com/u/6843156?v=3","gravatar_id":"","url":"https://api.github.com/users/joeyparrish","html_url":"https://github.com/joeyparrish","followers_url":"https://api.github.com/users/joeyparrish/followers","following_url":"https://api.github.com/users/joeyparrish/following{/other_user}","gists_url":"https://api.github.com/users/joeyparrish/gists{/gist_id}","starred_url":"https://api.github.com/users/joeyparrish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joeyparrish/subscriptions","organizations_url":"https://api.github.com/users/joeyparrish/orgs","repos_url":"https://api.github.com/users/joeyparrish/repos","events_url":"https://api.github.com/users/joeyparrish/events{/privacy}","received_events_url":"https://api.github.com/users/joeyparrish/received_events","type":"User","site_admin":false},"body":"This doesn't seem like the correct fix to me.  It seems that we should still remove cues.  Otherwise, when CC is re-enabled, the old cues are still there.  This could cause problems when we switch CC tracks and start adding new cues that conflict with the old ones.","created_at":"2016-05-02T09:28:38Z","updated_at":"2016-05-02T09:28:38Z","html_url":"https://github.com/google/shaka-player/pull/354#discussion_r61719750","pull_request_url":"https://api.github.com/repos/google/shaka-player/pulls/354","_links":{"self":{"href":"https://api.github.com/repos/google/shaka-player/pulls/comments/61719750"},"html":{"href":"https://github.com/google/shaka-player/pull/354#discussion_r61719750"},"pull_request":{"href":"https://api.github.com/repos/google/shaka-player/pulls/354"}}},"pull_request":{"url":"https://api.github.com/repos/google/shaka-player/pulls/354","id":67764722,"html_url":"https://github.com/google/shaka-player/pull/354","diff_url":"https://github.com/google/shaka-player/pull/354.diff","patch_url":"https://github.com/google/shaka-player/pull/354.patch","issue_url":"https://api.github.com/repos/google/shaka-player/issues/354","number":354,"state":"open","locked":false,"title":"text_engine: fix remove when TextTrack is in disabled mode","user":{"login":"baconz","id":1123782,"avatar_url":"https://avatars.githubusercontent.com/u/1123782?v=3","gravatar_id":"","url":"https://api.github.com/users/baconz","html_url":"https://github.com/baconz","followers_url":"https://api.github.com/users/baconz/followers","following_url":"https://api.github.com/users/baconz/following{/other_user}","gists_url":"https://api.github.com/users/baconz/gists{/gist_id}","starred_url":"https://api.github.com/users/baconz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baconz/subscriptions","organizations_url":"https://api.github.com/users/baconz/orgs","repos_url":"https://api.github.com/users/baconz/repos","events_url":"https://api.github.com/users/baconz/events{/privacy}","received_events_url":"https://api.github.com/users/baconz/received_events","type":"User","site_admin":false},"body":"If you disable CC the TextTrack ends up with cues set to null, which\r\nbreaks the async remove call on TextEngine. We should bail if there\r\nare no cues.","created_at":"2016-04-25T18:20:17Z","updated_at":"2016-05-02T09:28:38Z","closed_at":null,"merged_at":null,"merge_commit_sha":"40f0c62235f5cff9fbecd2932d481b9c9d6ad8e3","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/google/shaka-player/pulls/354/commits","review_comments_url":"https://api.github.com/repos/google/shaka-player/pulls/354/comments","review_comment_url":"https://api.github.com/repos/google/shaka-player/pulls/comments{/number}","comments_url":"https://api.github.com/repos/google/shaka-player/issues/354/comments","statuses_url":"https://api.github.com/repos/google/shaka-player/statuses/60443702c92bd38837d86617fcc1d069837b3e6b","head":{"label":"baconz:master","ref":"master","sha":"60443702c92bd38837d86617fcc1d069837b3e6b","user":{"login":"baconz","id":1123782,"avatar_url":"https://avatars.githubusercontent.com/u/1123782?v=3","gravatar_id":"","url":"https://api.github.com/users/baconz","html_url":"https://github.com/baconz","followers_url":"https://api.github.com/users/baconz/followers","following_url":"https://api.github.com/users/baconz/following{/other_user}","gists_url":"https://api.github.com/users/baconz/gists{/gist_id}","starred_url":"https://api.github.com/users/baconz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baconz/subscriptions","organizations_url":"https://api.github.com/users/baconz/orgs","repos_url":"https://api.github.com/users/baconz/repos","events_url":"https://api.github.com/users/baconz/events{/privacy}","received_events_url":"https://api.github.com/users/baconz/received_events","type":"User","site_admin":false},"repo":{"id":45582015,"name":"shaka-player","full_name":"baconz/shaka-player","owner":{"login":"baconz","id":1123782,"avatar_url":"https://avatars.githubusercontent.com/u/1123782?v=3","gravatar_id":"","url":"https://api.github.com/users/baconz","html_url":"https://github.com/baconz","followers_url":"https://api.github.com/users/baconz/followers","following_url":"https://api.github.com/users/baconz/following{/other_user}","gists_url":"https://api.github.com/users/baconz/gists{/gist_id}","starred_url":"https://api.github.com/users/baconz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baconz/subscriptions","organizations_url":"https://api.github.com/users/baconz/orgs","repos_url":"https://api.github.com/users/baconz/repos","events_url":"https://api.github.com/users/baconz/events{/privacy}","received_events_url":"https://api.github.com/users/baconz/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/baconz/shaka-player","description":"JavaScript player library / DASH client / MSE-EME player","fork":true,"url":"https://api.github.com/repos/baconz/shaka-player","forks_url":"https://api.github.com/repos/baconz/shaka-player/forks","keys_url":"https://api.github.com/repos/baconz/shaka-player/keys{/key_id}","collaborators_url":"https://api.github.com/repos/baconz/shaka-player/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/baconz/shaka-player/teams","hooks_url":"https://api.github.com/repos/baconz/shaka-player/hooks","issue_events_url":"https://api.github.com/repos/baconz/shaka-player/issues/events{/number}","events_url":"https://api.github.com/repos/baconz/shaka-player/events","assignees_url":"https://api.github.com/repos/baconz/shaka-player/assignees{/user}","branches_url":"https://api.github.com/repos/baconz/shaka-player/branches{/branch}","tags_url":"https://api.github.com/repos/baconz/shaka-player/tags","blobs_url":"https://api.github.com/repos/baconz/shaka-player/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/baconz/shaka-player/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/baconz/shaka-player/git/refs{/sha}","trees_url":"https://api.github.com/repos/baconz/shaka-player/git/trees{/sha}","statuses_url":"https://api.github.com/repos/baconz/shaka-player/statuses/{sha}","languages_url":"https://api.github.com/repos/baconz/shaka-player/languages","stargazers_url":"https://api.github.com/repos/baconz/shaka-player/stargazers","contributors_url":"https://api.github.com/repos/baconz/shaka-player/contributors","subscribers_url":"https://api.github.com/repos/baconz/shaka-player/subscribers","subscription_url":"https://api.github.com/repos/baconz/shaka-player/subscription","commits_url":"https://api.github.com/repos/baconz/shaka-player/commits{/sha}","git_commits_url":"https://api.github.com/repos/baconz/shaka-player/git/commits{/sha}","comments_url":"https://api.github.com/repos/baconz/shaka-player/comments{/number}","issue_comment_url":"https://api.github.com/repos/baconz/shaka-player/issues/comments{/number}","contents_url":"https://api.github.com/repos/baconz/shaka-player/contents/{+path}","compare_url":"https://api.github.com/repos/baconz/shaka-player/compare/{base}...{head}","merges_url":"https://api.github.com/repos/baconz/shaka-player/merges","archive_url":"https://api.github.com/repos/baconz/shaka-player/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/baconz/shaka-player/downloads","issues_url":"https://api.github.com/repos/baconz/shaka-player/issues{/number}","pulls_url":"https://api.github.com/repos/baconz/shaka-player/pulls{/number}","milestones_url":"https://api.github.com/repos/baconz/shaka-player/milestones{/number}","notifications_url":"https://api.github.com/repos/baconz/shaka-player/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/baconz/shaka-player/labels{/name}","releases_url":"https://api.github.com/repos/baconz/shaka-player/releases{/id}","deployments_url":"https://api.github.com/repos/baconz/shaka-player/deployments","created_at":"2015-11-05T02:30:52Z","updated_at":"2016-04-25T18:20:01Z","pushed_at":"2016-04-25T18:19:45Z","git_url":"git://github.com/baconz/shaka-player.git","ssh_url":"git@github.com:baconz/shaka-player.git","clone_url":"https://github.com/baconz/shaka-player.git","svn_url":"https://github.com/baconz/shaka-player","homepage":"","size":25491,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"google:master","ref":"master","sha":"f9552a5359f73b3c49d033aa51b0cb98ce6eb8d7","user":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":28246472,"name":"shaka-player","full_name":"google/shaka-player","owner":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/google/shaka-player","description":"JavaScript player library / DASH client / MSE-EME player","fork":false,"url":"https://api.github.com/repos/google/shaka-player","forks_url":"https://api.github.com/repos/google/shaka-player/forks","keys_url":"https://api.github.com/repos/google/shaka-player/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/shaka-player/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/shaka-player/teams","hooks_url":"https://api.github.com/repos/google/shaka-player/hooks","issue_events_url":"https://api.github.com/repos/google/shaka-player/issues/events{/number}","events_url":"https://api.github.com/repos/google/shaka-player/events","assignees_url":"https://api.github.com/repos/google/shaka-player/assignees{/user}","branches_url":"https://api.github.com/repos/google/shaka-player/branches{/branch}","tags_url":"https://api.github.com/repos/google/shaka-player/tags","blobs_url":"https://api.github.com/repos/google/shaka-player/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/shaka-player/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/shaka-player/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/shaka-player/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/shaka-player/statuses/{sha}","languages_url":"https://api.github.com/repos/google/shaka-player/languages","stargazers_url":"https://api.github.com/repos/google/shaka-player/stargazers","contributors_url":"https://api.github.com/repos/google/shaka-player/contributors","subscribers_url":"https://api.github.com/repos/google/shaka-player/subscribers","subscription_url":"https://api.github.com/repos/google/shaka-player/subscription","commits_url":"https://api.github.com/repos/google/shaka-player/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/shaka-player/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/shaka-player/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/shaka-player/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/shaka-player/contents/{+path}","compare_url":"https://api.github.com/repos/google/shaka-player/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/shaka-player/merges","archive_url":"https://api.github.com/repos/google/shaka-player/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/shaka-player/downloads","issues_url":"https://api.github.com/repos/google/shaka-player/issues{/number}","pulls_url":"https://api.github.com/repos/google/shaka-player/pulls{/number}","milestones_url":"https://api.github.com/repos/google/shaka-player/milestones{/number}","notifications_url":"https://api.github.com/repos/google/shaka-player/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/shaka-player/labels{/name}","releases_url":"https://api.github.com/repos/google/shaka-player/releases{/id}","deployments_url":"https://api.github.com/repos/google/shaka-player/deployments","created_at":"2014-12-19T21:12:18Z","updated_at":"2016-04-29T16:01:24Z","pushed_at":"2016-04-28T20:30:15Z","git_url":"git://github.com/google/shaka-player.git","ssh_url":"git@github.com:google/shaka-player.git","clone_url":"https://github.com/google/shaka-player.git","svn_url":"https://github.com/google/shaka-player","homepage":"","size":26448,"stargazers_count":579,"watchers_count":579,"language":"JavaScript","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":129,"mirror_url":null,"open_issues_count":34,"forks":129,"open_issues":34,"watchers":579,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/shaka-player/pulls/354"},"html":{"href":"https://github.com/google/shaka-player/pull/354"},"issue":{"href":"https://api.github.com/repos/google/shaka-player/issues/354"},"comments":{"href":"https://api.github.com/repos/google/shaka-player/issues/354/comments"},"review_comments":{"href":"https://api.github.com/repos/google/shaka-player/pulls/354/comments"},"review_comment":{"href":"https://api.github.com/repos/google/shaka-player/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/google/shaka-player/pulls/354/commits"},"statuses":{"href":"https://api.github.com/repos/google/shaka-player/statuses/60443702c92bd38837d86617fcc1d069837b3e6b"}}}}