Skip to content

Commit e1a9cc1

Browse files
committed
[Open311] Remove trailing whitespace
1 parent a3ae305 commit e1a9cc1

File tree

2 files changed

+25
-25
lines changed

2 files changed

+25
-25
lines changed

perllib/Open311/Endpoint.pm

+23-23
Original file line numberDiff line numberDiff line change
@@ -133,15 +133,15 @@ sub check_jurisdiction_id {
133133
* jurisdictions - an array of jurisdiction_ids
134134
you may want to subclass the methods:
135135
- requires_jurisdiction_ids
136-
- check_jurisdiction_id
136+
- check_jurisdiction_id
137137
* default_identifier_type
138138
Open311 doesn't mandate what these types look like, but a backend
139139
server may! The module provides an example identifier type which allows
140140
ascii "word" characters .e.g [a-zA-Z0-9_] as an example default.
141141
You can also override these individually using:
142142
143143
identifier_types => {
144-
api_key => '//str', #
144+
api_key => '//str', #
145145
jurisdiction_id => ...
146146
service_code => ...
147147
service_request_id => ...
@@ -246,9 +246,9 @@ has json => (
246246
has xml => (
247247
is => 'lazy',
248248
default => sub {
249-
XML::Simple->new(
250-
NoAttr=> 1,
251-
KeepRoot => 1,
249+
XML::Simple->new(
250+
NoAttr=> 1,
251+
KeepRoot => 1,
252252
SuppressEmpty => 0,
253253
);
254254
},
@@ -419,15 +419,15 @@ sub GET_Service_Definition {
419419
%optional,
420420
$attribute->has_values ? (
421421
values => [
422-
map {
422+
map {
423423
my ($key, $name) = @$_;
424-
+{
425-
key => $key,
424+
+{
425+
key => $key,
426426
name => $name,
427427
}
428428
} $self->service_attribute_values( $attribute )
429429
]) : (),
430-
map { $_ => $attribute->$_ }
430+
map { $_ => $attribute->$_ }
431431
qw/ code datatype datatype_description description /,
432432
}
433433
} $service->get_attributes,
@@ -456,8 +456,8 @@ sub POST_Service_Request_input_schema {
456456
# to give a nice error message
457457
return {
458458
type => '//rec',
459-
required => {
460-
service_code => $self->get_identifier_type('service_code'),
459+
required => {
460+
service_code => $self->get_identifier_type('service_code'),
461461
api_key => $self->get_identifier_type('api_key') },
462462
rest => '//any',
463463
};
@@ -518,7 +518,7 @@ sub POST_Service_Request_input_schema {
518518
};
519519
}
520520

521-
return {
521+
return {
522522
type => '//any',
523523
of => \@address_schemas,
524524
};
@@ -571,12 +571,12 @@ sub POST_Service_Request {
571571
}
572572

573573
my @service_requests = $self->post_service_request( $service, $args );
574-
574+
575575
return {
576576
service_requests => [
577577
map {
578-
my $service_notice =
579-
$_->service_notice
578+
my $service_notice =
579+
$_->service_notice
580580
|| $service->default_service_notice
581581
|| $self->default_service_notice;
582582
+{
@@ -754,7 +754,7 @@ sub format_service_requests {
754754
zipcode
755755
lat
756756
long
757-
/
757+
/
758758
),
759759
(
760760
map {
@@ -812,11 +812,11 @@ sub get_jurisdiction_id_validation {
812812

813813
# jurisdiction_id is documented as "Required", but with the note
814814
# 'This is only required if the endpoint serves multiple jurisdictions'
815-
# i.e. it is optional as regards the schema, but the server may choose
815+
# i.e. it is optional as regards the schema, but the server may choose
816816
# to error if it is not provided.
817817
return {
818818
type => '//rec',
819-
($self->requires_jurisdiction_ids ? 'required' : 'optional') => {
819+
($self->requires_jurisdiction_ids ? 'required' : 'optional') => {
820820
jurisdiction_id => $self->get_identifier_type('jurisdiction_id'),
821821
},
822822
};
@@ -834,7 +834,7 @@ sub get_jurisdiction_id_optional_clause {
834834

835835
sub call_api {
836836
my ($self, $api_name, @args) = @_;
837-
837+
838838
my $api_method = $self->can($api_name)
839839
or die "No such API $api_name!";
840840

@@ -894,10 +894,10 @@ sub format_response {
894894
my $data = $response->data;
895895
if ($ext eq 'json') {
896896
return [
897-
$status,
897+
$status,
898898
[ 'Content-Type' => 'application/json' ],
899-
[ $self->json->encode(
900-
$self->spark->process_for_json( $data )
899+
[ $self->json->encode(
900+
$self->spark->process_for_json( $data )
901901
)]
902902
];
903903
}
@@ -916,7 +916,7 @@ sub format_response {
916916
404,
917917
[ 'Content-Type' => 'text/plain' ],
918918
[ 'Bad extension. We support .xml and .json' ],
919-
]
919+
]
920920
}
921921
}
922922
}

perllib/Open311/Endpoint/Service/Attribute.pm

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ has code => (
1919
has variable => (
2020
is => 'ro',
2121
isa => Bool,
22-
default => sub { 1 },
22+
default => sub { 1 },
2323
);
2424

2525
# Denotes the type of field used for user input.
@@ -41,7 +41,7 @@ has datatype_description => (
4141
);
4242

4343
# A description of the attribute field with instructions for the user to find
44-
# and identify the requested information
44+
# and identify the requested information
4545
has description => (
4646
is => 'ro',
4747
isa => Str,

0 commit comments

Comments
 (0)