Conversation
|
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
|
Code changes look good to me. If that's the case I wonder what happens if all apps have the same priority? Should we then do an alphabetical order, too? Or isn't it up to the client how to sort these apps? |
@wkloucek the aim here is that the list presented to the user doesn't change as the service restarts to reduce confusion from the end-user perspective. Imagine, you click and you have "Open in OnlyOffice" as first entry and then when the service restarts you'll have it at the end. |

Before the order of the list returned by the method FindProviders of app providers depended from the order in which the app provider registered themselves.
Now, it is possible to specify a priority for each app provider, and even if an app provider re-register itself (for example after a restart), the order is kept.
This PR also remove all the code used to keep the default app provider always to the top of the list for each mime type, as now the cs3apis support the field DefaultApplication (#2230 cs3org/cs3apis#157)