Skip to content

Commit

Permalink
seems to be a bug in the filter plugin. small check to see if the pat…
Browse files Browse the repository at this point in the history
…h has already been added and if so just skips to the next. fixes [#42 state:resolved]
  • Loading branch information
dogmatic69 committed Dec 31, 2009
1 parent 451cc42 commit 82e04d7
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion plugins/filter/views/helpers/filter.php
Expand Up @@ -5,6 +5,8 @@ class FilterHelper extends Helper
'Form', 'Html'
);

var $count = 0;

function form( $model, $fields = array() )
{
$output = '<tr>';
Expand Down Expand Up @@ -63,13 +65,17 @@ function clear( $filter )
'<div class="wrap">';
$parts = explode( '/', $filter['url'][0] );

$done = array();

foreach( $parts as $_f )
{
if ( empty( $_f ) )
if ( empty( $_f ) || in_array( $_f, $done ) )
{
continue;
}

$done[] = $_f;

$text = explode( ':', $_f );
$text = explode( '.', $text[0] );
$text = ( count( $text ) > 1 ) ? $text[1] : $text[0];
Expand Down

0 comments on commit 82e04d7

Please sign in to comment.