Skip to content

Commit 81b3938

Browse files
committed
fix (cs) update rules
1 parent ba87afd commit 81b3938

File tree

3 files changed

+3
-9
lines changed

3 files changed

+3
-9
lines changed

grumphp.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ grumphp:
3131
triggered_by: ['php']
3232
show_info: true
3333
testsuites: []
34-
extensions: []
34+
extensions: []

inc/Helpers/Formatting/Link.php

+1-7
Original file line numberDiff line numberDiff line change
@@ -150,13 +150,7 @@ function get_the_link( array $attributes, array $settings = [] ): string {
150150
$attributes = apply_filters( 'bea_theme_framework_link_attributes', $attributes, $settings );
151151

152152
// revove empty attributes
153-
154-
if ( empty( $attributes['title'] ) ) {
155-
unset( $attributes['title'] );
156-
}
157-
if ( empty( $attributes['target'] ) ) {
158-
unset( $attributes['target'] );
159-
}
153+
$attributes = array_filter( $attributes );
160154

161155
$settings = wp_parse_args(
162156
$settings,

phpcs.xml.dist

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0"?>
22
<ruleset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3-
name="WP Skeleton"
3+
name="Beapi frontend framework"
44
xsi:noNamespaceSchemaLocation="https://raw.githubusercontent.com/squizlabs/PHP_CodeSniffer/master/phpcs.xsd">
55

66
<description>A custom set of rules to check for a WPized WordPress project</description>

0 commit comments

Comments
 (0)