summaryrefslogtreecommitdiffstats
path: root/mdkonline.pm
diff options
context:
space:
mode:
authorDaouda Lo <daouda@mandriva.com>2005-09-15 16:57:47 +0000
committerDaouda Lo <daouda@mandriva.com>2005-09-15 16:57:47 +0000
commit1bf180ae62a2ad6c5e1d20bc5251d10ce4f2b5ff (patch)
tree19af16c40c806594f89d4ad23b1d6d7151838873 /mdkonline.pm
parent0dfac7be3d89d6a418f4d3232bff515ae28df6e4 (diff)
downloadmgaonline-1bf180ae62a2ad6c5e1d20bc5251d10ce4f2b5ff.tar
mgaonline-1bf180ae62a2ad6c5e1d20bc5251d10ce4f2b5ff.tar.gz
mgaonline-1bf180ae62a2ad6c5e1d20bc5251d10ce4f2b5ff.tar.bz2
mgaonline-1bf180ae62a2ad6c5e1d20bc5251d10ce4f2b5ff.tar.xz
mgaonline-1bf180ae62a2ad6c5e1d20bc5251d10ce4f2b5ff.zip
- closures can be nasty sometimes :-(
Diffstat (limited to 'mdkonline.pm')
-rw-r--r--mdkonline.pm10
1 files changed, 7 insertions, 3 deletions
diff --git a/mdkonline.pm b/mdkonline.pm
index c158294f..836a1fcf 100644
--- a/mdkonline.pm
+++ b/mdkonline.pm
@@ -13,6 +13,9 @@ use HTTP::Request::Common;
use HTTP::Request;
use SOAP::Lite;
+#For debugging
+use Data::Dumper;
+
my $release_file = find { -f $_ } '/etc/mandriva-release', '/etc/mandrakelinux-release', '/etc/mandrake-release', '/etc/redhat-release';
my $uri = 'https://my.mandriva.com/soap/';
my $serviceProxy = 'https://my.mandriva.com/soap/';
@@ -71,7 +74,8 @@ sub get_site {
}
sub create_authenticate_account {
- my ($type) = shift;
+ my $type = shift;
+ my @info = @_;
my ($response, $code);
my $hreturn = {
1 => [ N("Security error"), N("Unsecure invocation: Method available through httpS only") ],
@@ -91,7 +95,7 @@ sub create_authenticate_account {
foreach my $num ([9, 8], [21, 20]) { $hreturn->{$num->[0]} = $hreturn->{$num->[1]} };
my $action = {
create => sub {
- eval { $response = soap_create_account(@_) };
+ eval { $response = soap_create_account(@info) };
if ($response->{status}) {
return 'OK';
} else {
@@ -100,7 +104,7 @@ sub create_authenticate_account {
}
},
authenticate => sub {
- eval { $response = soap_authenticate_user(@_) };
+ eval { $response = soap_authenticate_user(@info) };
if ($response->{status}) {
return 'OK'
} else {