ResourceUtils.isUrl(location) might be better here