blob: e24a7fd639a085f8a6cd1321008cb70239172466 [file] [log] [blame]
// Copyright 2018 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/resource_coordinator/utils.h"
#include "base/md5.h"
namespace resource_coordinator {
std::string SerializeOriginIntoDatabaseKey(const url::Origin& origin) {
return base::MD5String(origin.host());
}
bool URLShouldBeStoredInLocalDatabase(const GURL& url) {
// Only store information for the HTTP(S) sites for now.
return url.SchemeIsHTTPOrHTTPS();
}
} // namespace resource_coordinator