Skip to content

Commit

Permalink
cleanup rogue whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
shadowcat-mst committed Jul 24, 2020
1 parent 91daef0 commit b775020
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion lib/SQL/Abstract.pm
Original file line number Diff line number Diff line change
Expand Up @@ -1284,7 +1284,7 @@ sub _expand_bool {
sub _expand_list {
my ($self, undef, $expr) = @_;
return { -op => [
',', map $self->expand_expr($_),
',', map $self->expand_expr($_),
@{$expr->{-op}}[1..$#{$expr->{-op}}]
] } if ref($expr) eq 'HASH' and ($expr->{-op}||[''])->[0] eq ',';
return +{ -op => [ ',',
Expand Down
2 changes: 1 addition & 1 deletion lib/SQL/Abstract/Formatter.pm
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,4 @@ sub _fold_sql {
return join '', @res, $line;
}

1;
1;
2 changes: 1 addition & 1 deletion t/05in_between.t
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ for my $case (@in_between_tests) {
warnings_are {
($stmt, @bind) = $sql->where($case->{where});
} [], "$label gives no warnings";

is_same_sql_bind(
$stmt,
\@bind,
Expand Down
32 changes: 16 additions & 16 deletions t/80extra_clauses.t
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ is_same_sql(


($sql, @bind) = $sqlac->insert({
with => [
with => [
faculty => {
-select => {
_ => [qw /p.person p.email/],
Expand All @@ -288,7 +288,7 @@ is_same_sql(
into => 'license',
fields => [ qw(kind expires_on valid_from) ],
select => {
select => [\(qw('grandfather' '2017-06-30' '2016-07-01'))],
select => [\(qw('grandfather' '2017-06-30' '2016-07-01'))],
from => 'faculty',
},
returning => 'license_id',
Expand Down Expand Up @@ -328,7 +328,7 @@ is_same_sql_bind(


($sql, @bind) = $sqlac->delete({
with => [
with => [
instructors => {
-select => {
_ => [qw/p.person_id email default_license_id/],
Expand All @@ -338,12 +338,12 @@ is_same_sql_bind(
to => 'license_person',
as => 'lp',
on => { 'lp.person_id' => 'p.person_id' },
},
},
-join => {
to => 'license',
as => 'l',
on => { 'l.license_id' => 'lp.license_id' },
},
},
],
where => {
'p.person_type' => 'faculty',
Expand All @@ -363,15 +363,15 @@ is_same_sql_bind(
to => 'license_person',
as => 'lp',
on => { 'lp.person_id' => 'i.person_id' },
},
},
-join => {
to => 'license',
as => 'l',
on => { 'l.license_id' => 'lp.license_id' },
},
},
],
where => {
'lp.license_id' => {
'lp.license_id' => {
'<>' => {-ident => 'i.default_license_id'}
},
'l.kind' => 'pending',
Expand All @@ -381,10 +381,10 @@ is_same_sql_bind(
],
from => 'license_person',
where => {
ctid => { -in =>
ctid => { -in =>
{
-select => {
_ => ['ctid'],
_ => ['ctid'],
from => 'deletable_licenses',
}
}
Expand All @@ -400,8 +400,8 @@ is_same_sql_bind(
from person as p
join license_person as lp on lp.person_id = p.person_id
join license as l on l.license_id = lp.license_id
where l.kind = ?
AND p.person_status != ?
where l.kind = ?
AND p.person_status != ?
AND p.person_type = ?
group by p.person_id
having COUNT(l.license_id) > ?),
Expand All @@ -413,7 +413,7 @@ is_same_sql_bind(
where l.kind = ?
and lp.license_id <> i.default_license_id
)
delete from license_person
delete from license_person
where ctid IN (
(select ctid from deletable_licenses)
)
Expand All @@ -428,7 +428,7 @@ is_same_sql_bind(
set => {
license_id => { -ident => 'info.default_license_id' },
},
from => [
from => [
-select => {
select => [qw( s.survey_id p.default_license_id p.person_id)],
from => [
Expand All @@ -437,12 +437,12 @@ is_same_sql_bind(
to => 'class',
as => 'c',
on => { 'c.faculty_id' => 'p.person_id' },
},
},
-join => {
to => 'survey',
as => 's',
on => { 's.class_id' => 'c.class_id' },
},
},
],
where => { 'p.institution_id' => { -value => 15031 } },
},
Expand Down

0 comments on commit b775020

Please sign in to comment.