Skip to content

Commit 2f83314

Browse files
authored
Merge pull request #568 from Automattic/master
Release Aug 11
2 parents ced31ea + e0a5a83 commit 2f83314

File tree

8 files changed

+565
-196
lines changed

8 files changed

+565
-196
lines changed

.circleci/config.yml

+6-1
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ jobs:
3535
- image: circleci/node:12
3636
steps:
3737
- checkout_code
38+
- run:
39+
name: Install rsync
40+
command: sudo apt install rsync
3841
- run:
3942
name: Release new version
4043
command: npm run release
@@ -52,4 +55,6 @@ workflows:
5255
- build
5356
filters:
5457
branches:
55-
only: release
58+
only:
59+
- release
60+
- alpha

.distignore

+5-3
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
Thumbs.db
1010
behat.yml
1111
bitbucket-pipelines.yml
12-
bin
1312
.circleci/config.yml
1413
composer.json
1514
composer.lock
@@ -27,9 +26,12 @@ phpcs.xml.dist
2726
README.md
2827
wp-cli.local.yml
2928
yarn.lock
30-
tests
31-
vendor
3229
node_modules
3330
*.sql
3431
*.tar.gz
3532
*.zip
33+
.github
34+
.circleci
35+
/release
36+
/tests
37+
/bin

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ node_modules/
1010

1111
/vendor/
1212
dist/
13-
assets/
13+
release/

class-newspack-blocks-api.php

+6
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,9 @@ public static function register_video_playlist_endpoint() {
271271
[
272272
'methods' => 'GET',
273273
'callback' => [ 'Newspack_Blocks_API', 'video_playlist_endpoint' ],
274+
'permission_callback' => function( $request ) {
275+
return current_user_can( 'edit_posts' );
276+
},
274277
]
275278
);
276279
}
@@ -296,6 +299,9 @@ public static function register_post_lookup_endpoint() {
296299
'sanitize_callback' => 'absint',
297300
],
298301
],
302+
'permission_callback' => function( $request ) {
303+
return current_user_can( 'edit_posts' );
304+
},
299305
]
300306
);
301307
}

composer.json

+1-3
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,8 @@
22
"name": "automattic/newspack-blocks",
33
"description": "Gutenberg blocks for Newspack.",
44
"type": "wordpress-plugin",
5-
"require": {
6-
"composer/installers": "~1.6"
7-
},
85
"require-dev": {
6+
"composer/installers": "~1.6",
97
"automattic/vipwpcs": "^2.0.0",
108
"xwp/wp-dev-lib": "^1.5",
119
"brainmaestro/composer-git-hooks": "^2.6",

0 commit comments

Comments
 (0)