Subject: | Can't locate object method "message" via package "Net::Google::Drive::Simple" |
error noticed while using version 0.13
Error: Validation for transport "Google Drive 1EB" failed: Could not upload test file: Can't locate object method "message" via package "Net::Google::Drive::Simple" at /usr/local/cpanel/3rdparty/perl/524/lib64/perl5/cpanel_lib/Net/Google/Drive/Simple.pm line 259.
Attached is a candidate patch to fix this issue
Subject: | warning.patch |
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: "brian m. carlson" <brian.carlson@cpanel.net>
Date: Thu, 17 May 2018 13:35:41 +0000
Subject: [PATCH 3/3] Fix undefined method error
Case CPANEL-19001: Fix the undefined method error that occurs by trying
to call the message method on $self instead of on $resp.
---
.../Net-Google-Drive-Simple/lib/Net/Google/Drive/Simple.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/modules/Net-Google-Drive-Simple/Net-Google-Drive-Simple/lib/Net/Google/Drive/Simple.pm b/modules/Net-Google-Drive-Simple/Net-Google-Drive-Simple/lib/Net/Google/Drive/Simple.pm
index 3a4ded4e4..f805b10a8 100644
--- a/modules/Net-Google-Drive-Simple/Net-Google-Drive-Simple/lib/Net/Google/Drive/Simple.pm
+++ b/modules/Net-Google-Drive-Simple/Net-Google-Drive-Simple/lib/Net/Google/Drive/Simple.pm
@@ -256,7 +256,7 @@ sub file_upload {
my $resp = $self->http_loop( $req );
if( $resp->is_error() ) {
- $self->error( $self->message() );
+ $self->error( $resp->message() );
return undef;
}