Completed
Push — master ( ee5418...1580be )
by
unknown
01:50
created
includes/process/meta.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -28,9 +28,9 @@  discard block
 block discarded – undo
28 28
 	 *
29 29
 	 * @return bool Always returns true.
30 30
 	 */
31
-	public function update( $data ) {
31
+	public function update($data) {
32 32
 
33
-		$post_id = isset( $data['post_id'] ) ? $data['post_id'] : false;
33
+		$post_id = isset($data['post_id']) ? $data['post_id'] : false;
34 34
 
35 35
 			
36 36
 		/**
@@ -40,13 +40,13 @@  discard block
 block discarded – undo
40 40
 		 *
41 41
 		 * @param array $allowed_fields The fields
42 42
 		 */
43
-		$allowed_fields = apply_filters( 'lasso_meta_fields', array() );
44
-		if ( ! empty( $allowed_fields ) ) {
45
-			foreach( $allowed_fields as $field ) {
46
-				if ( isset( $data[ $field ] ) ) {
43
+		$allowed_fields = apply_filters('lasso_meta_fields', array());
44
+		if (!empty($allowed_fields)) {
45
+			foreach ($allowed_fields as $field) {
46
+				if (isset($data[$field])) {
47 47
 					//this original line changed dash to underscore
48 48
 					//update_post_meta( $post_id, lasso_unclean_string( $field ), $data[ $field ]  );
49
-					update_post_meta( $post_id,  $field, $data[ $field ]  );
49
+					update_post_meta($post_id, $field, $data[$field]);
50 50
 				}
51 51
 			}
52 52
 		}
@@ -64,8 +64,8 @@  discard block
 block discarded – undo
64 64
 	 *
65 65
 	 * @return array Array of keys to pull from $data per action and their sanitization callback
66 66
 	 */
67
-	public static function params(){
68
-		$params[ 'process_meta_update' ] = array(
67
+	public static function params() {
68
+		$params['process_meta_update'] = array(
69 69
 			'post_id' 	=> 'absint',
70 70
 			'tab_name'	=> 'trim'
71 71
 		);
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
 	 * @return array Array of additional functions to use to authorize action.
83 83
 	 */
84 84
 	public static function auth_callbacks() {
85
-		$params[ 'process_meta_update' ] = array(
85
+		$params['process_meta_update'] = array(
86 86
 			'lasso_user_can'
87 87
 		);
88 88
 
Please login to merge, or discard this patch.