How and when should this feature warn about missing upload adapter? #2824
Labels
package:upload
status:discussion
type:improvement
This issue reports a possible enhancement of an existing feature.
Followup of #569.
Right now, if you enable any image upload functionality without configuring or loading any adapter, there will be no warning on startup. However, an error will be logged if you paste or drop an image and if you try to use the "Insert image" button.
The problem is that the image upload features are enabled by default in all builds. Which means that people may get warnings even though they are not interested in upload at all.
OTOH, silent errors are what developers hate. I can feel how furious I'd be myself when after enabling an
UploadImage
plugin I'd get no warning or anything when I tried to paste/drop an image. For developers, this is awful. And documentation won't help here – many of the developers will not read it that precisely or at all. Especially that this process is always made of at least two steps – enabling an adapter and configuring it.Furthermore, there are issues like when should the "Insert image" button log a warning? When added to the toolbar? When used?
Also, a thing to consider is that checking the existence of an adapter in all these features will bloat a code (not in terms of size but complexity). Perhaps it would be wise to add
FileLoader#assertLoader()
method which would log a standardised warning if needed.The text was updated successfully, but these errors were encountered: