Completed
Push — update/update-post-json-endpoi... ( c5a14b )
by
unknown
119:28 queued 107:50
created
require-lib.php 1 patch
Doc Comments   +9 added lines patch added patch discarded remove patch
@@ -1,5 +1,8 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
+/**
4
+ * @param string $lib_dir
5
+ */
3 6
 function require_lib_from_dir( $slug, $lib_dir ) {
4 7
 	if ( !preg_match( '|^[a-z0-9/_.-]+$|i', $slug ) ) {
5 8
 		trigger_error( "Cannot load a library with invalid slug $slug.", E_USER_ERROR );
@@ -29,6 +32,9 @@  discard block
 block discarded – undo
29 32
 	trigger_error( "Cannot find a library with slug $slug.", E_USER_ERROR );
30 33
 }
31 34
 
35
+/**
36
+ * @param string $slug
37
+ */
32 38
 function jetpack_require_lib( $slug ) {
33 39
    if ( defined( 'ABSPATH' ) && ! defined( 'WP_CONTENT_DIR' ) ) {
34 40
        define( 'WP_CONTENT_DIR', ABSPATH . 'wp-content' ); // no trailing slash, full paths only - WP_CONTENT_URL is defined further down
@@ -37,6 +43,9 @@  discard block
 block discarded – undo
37 43
    require_lib_from_dir( $slug, WP_CONTENT_DIR . '/lib' );
38 44
 }
39 45
 
46
+/**
47
+ * @param string $slug
48
+ */
40 49
 function jetpack_require_lib( $slug ) {
41 50
    require_lib_from_dir( $slug, JETPACK__PLUGIN_DIR . '/_inc/lib' );
42 51
 }
Please login to merge, or discard this patch.