make `core upgrade` an alias of `core update`
Avoid warning if no rewrite rules exist
Show messages as warnings, and change JSON output to empty array, not string
Clean up logic
.
.