This website works better with JavaScript.
Home
Explore
Help
Sign In
nekobus
/
mastodon_neko
forked from
closed-social/mastodon
Watch
1
Star
0
Fork
0
Code
Issues
0
Pull Requests
0
Projects
0
Releases
0
Wiki
Activity
Browse Source
Fix error when closing a playing audio or video modal (
#14310
)
closed-social-v3
ThibG
4 years ago
committed by
GitHub
parent
6f798eb574
commit
bfed7dd5f3
No known key found for this signature in database
GPG Key ID:
4AEE18F83AFDEB23
2 changed files
with
4 additions
and
0 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+2
-0
app/javascript/mastodon/features/audio/index.js
+2
-0
app/javascript/mastodon/features/video/index.js
+ 2
- 0
app/javascript/mastodon/features/audio/index.js
View File
@ -298,6 +298,8 @@ class Audio extends React.PureComponent {
_renderCanvas
(
)
{
requestAnimationFrame
(
(
)
=>
{
if
(
!
this
.
audio
)
return
;
this
.
handleTimeUpdate
(
)
;
this
.
_clear
(
)
;
this
.
_draw
(
)
;
+ 2
- 0
app/javascript/mastodon/features/video/index.js
View File
@ -182,6 +182,8 @@ class Video extends React.PureComponent {
_updateTime
(
)
{
requestAnimationFrame
(
(
)
=>
{
if
(
!
this
.
video
)
return
;
this
.
handleTimeUpdate
(
)
;
if
(
!
this
.
state
.
paused
)
{
Write
Preview
Loading…
Cancel
Save