If a post is initially soft deleted and later on a user wants to permanently delete the post, there is a "string to array conversion" error. While the error is only thrown in my development environment (with twig debug enabled), it is still there.
Soft deleted post: https://prnt.sc/m7kxvf
When clicking on delete: https://prnt.sc/m7ky32
And with Twig debug enabled: http://prntscr.com/m7kzzq
The problem is that the language key send to confirm_box() is an array. Meaning that it has a plural form.
'DELETE_POST_PERMANENTLY' => array( |
1 => 'Permanently delete this post so it can not be recovered', |
2 => 'Permanently delete %1$d posts so they can not be recovered', |
),
|
Therefore I propose to allow sending an array to the confirm_box() language string, which will allow sending parameters for plural form (or for other things aswell such as %s).