| Index: extensions/renderer/api_invocation_errors.cc
|
| diff --git a/extensions/renderer/api_invocation_errors.cc b/extensions/renderer/api_invocation_errors.cc
|
| index 34d147ff20b5b5ad28e0f5ed8397b0548f435955..58c0784aeda8a8c2bb0eac1dea2041c86aec9b92 100644
|
| --- a/extensions/renderer/api_invocation_errors.cc
|
| +++ b/extensions/renderer/api_invocation_errors.cc
|
| @@ -87,6 +87,14 @@ std::string ScriptThrewError() {
|
| return "Script threw an error.";
|
| }
|
|
|
| +std::string TooManyArguments() {
|
| + return "Too many arguments.";
|
| +}
|
| +
|
| +std::string MissingRequiredArgument(const char* argument_name) {
|
| + return base::StringPrintf("Missing required argument '%s'.", argument_name);
|
| +}
|
| +
|
| std::string IndexError(uint32_t index, const std::string& error) {
|
| return base::StringPrintf("Error at index %u: %s", index, error.c_str());
|
| }
|
| @@ -96,5 +104,11 @@ std::string PropertyError(const char* property_name, const std::string& error) {
|
| error.c_str());
|
| }
|
|
|
| +std::string ArgumentError(const std::string& parameter_name,
|
| + const std::string& error) {
|
| + return base::StringPrintf("Error at parameter '%s': %s",
|
| + parameter_name.c_str(), error.c_str());
|
| +}
|
| +
|
| } // namespace api_errors
|
| } // namespace extensions
|
|
|