| 1 | | The offset could be 0 for the first feed (obviously), and then the the sum of `$args['items']` of the previous feed(s) for the next one(s). |
| 2 | | With the current feeds this would pull 1 item from the first feed and 3+1 from the second. |
| 3 | | And if I am not mistaken this is exactly the margin needed to anticipate duplicates even in case the `'items'` args values change or if another feed is added in the future. |
| 4 | | I'm not even sure this will ever happen, but I like to avoid arbitrary and make things as flexible as possible :) |
| | 1 | Thinking about it, the necessary offset to handle possible duplicates is actually the number of items already displayed. Since we keep them in an array already to check for duplicate, we can conveniently count them. |
| | 2 | So basically: |
| | 3 | |
| | 4 | {{{ |
| | 5 | $args['items'] = $args['items'] + count( $displayed_links ); |
| | 6 | }}} |
| | 7 | |
| | 8 | This will also work in case the `'items'` args values change or if another feed is added in the future. I'm not sure this will ever happen, but I like to make things as flexible as possible :) |