afuna: Cat under a blanket. Text: "Cats are just little people with Fur and Fangs" (Default)
afuna ([personal profile] afuna) wrote in [site community profile] changelog2009-07-05 10:45 am

[dw-free] Viewing entries moderation queue doesn't display non-whitelisted videos

[commit: http://hg.dwscoalition.org/dw-free/rev/c96b2f3cf427]

http://bugs.dwscoalition.org/show_bug.cgi?id=1357

Codemerge. Display videos in moderation queue

Patch from LiveJournal; prepared for Dreamwidth by [staff profile] denise.

Files modified:
  • cgi-bin/ljprotocol.pl
  • htdocs/community/moderate.bml
--------------------------------------------------------------------------------
diff -r 5b84bd8fb073 -r c96b2f3cf427 cgi-bin/ljprotocol.pl
--- a/cgi-bin/ljprotocol.pl	Sun Jul 05 10:38:48 2009 +0000
+++ b/cgi-bin/ljprotocol.pl	Sun Jul 05 10:43:27 2009 +0000
@@ -1260,6 +1260,10 @@ sub postevent
             return fail($err, 408) if $modcount >= LJ::get_cap($uowner, "mod_queue_per_poster");
 
             $req->{'_moderate'}->{'authcode'} = LJ::make_auth_code(15);
+
+            # create tag <lj-embed> from HTML-tag <embed>
+            LJ::EmbedModule->parse_module_embed($u, \$req->{event});
+
             my $fr = $dbcm->quote(Storable::freeze($req));
             return fail($err, 409) if length($fr) > 600_000;
 
diff -r 5b84bd8fb073 -r c96b2f3cf427 htdocs/community/moderate.bml
--- a/htdocs/community/moderate.bml	Sun Jul 05 10:38:48 2009 +0000
+++ b/htdocs/community/moderate.bml	Sun Jul 05 10:43:27 2009 +0000
@@ -355,6 +355,10 @@ body<=
                                              'cutpreview' => 1,
                                              'cuturl' => '#',
                                          });
+
+        # create iframe from <lj-embed> tag
+        LJ::EmbedModule->expand_entry($up, \$event);
+
         BML::ebml(\$event);
 
         $ret .= "<p>";
--------------------------------------------------------------------------------

Post a comment in response:

This account has disabled anonymous posting.
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org