File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -36,10 +36,12 @@ functions.cloudEvent('blurOffensiveImages', async cloudEvent => {
3636 const name = cloudEvent . data . name ;
3737
3838 if ( bucket === BLURRED_BUCKET_NAME ) {
39- console . log ( 'Event triggered by the blurred bucket; skip to avoid recursion' )
39+ console . log (
40+ 'Event triggered by the blurred bucket; skip to avoid recursion'
41+ ) ;
4042 return ;
4143 }
42-
44+
4345 const file = storage . bucket ( bucket ) . file ( name ) ;
4446 const filePath = `gs://${ bucket } /${ name } ` ;
4547
@@ -67,7 +69,7 @@ functions.cloudEvent('blurOffensiveImages', async cloudEvent => {
6769// [END functions_imagemagick_analyze]
6870
6971// [START functions_imagemagick_blur]
70- // Blurs the given file using ImageMagick , and uploads it to another bucket.
72+ // Blurs the given file using sharp , and uploads it to another bucket.
7173const blurImage = async ( file , blurredBucketName ) => {
7274 const tempLocalPath = `/tmp/${ path . parse ( file . name ) . base } ` ;
7375 const tempLocalBlurredPath = `/tmp/blurred-${ path . parse ( file . name ) . base } ` ;
You can’t perform that action at this time.
0 commit comments