Skip to content

Commit

Permalink
addressed sonar cloud issues.
Browse files Browse the repository at this point in the history
  • Loading branch information
Nick Taras authored and Nick Taras committed Feb 27, 2023
1 parent 388b69f commit 2ec44ac
Show file tree
Hide file tree
Showing 20 changed files with 18 additions and 27 deletions.
2 changes: 1 addition & 1 deletion angular-bare-bones-demo/src/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ getTestBed().initTestEnvironment(
// Then we find all the tests.
const context = require.context('./', true, /\.spec\.ts$/);
// And load the modules.
context.keys().map(context);
context.keys().forEach(context);
2 changes: 1 addition & 1 deletion ecommerce-store-website/src/ui/app/context/context.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const Context = React.forwardRef( ( props, ref ) => {
</div>
</div>
</header>
{ children && children }
{ children }
</a.div>
);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@
grid-column: 2 / 4;
width: 100%;
padding: 0;
margin: 0;
flex-direction: row;
justify-content: flex-start;
grid-column-gap: var(--grid-gutter-width);
Expand Down
2 changes: 1 addition & 1 deletion ecommerce-store-website/src/ui/app/layout/layout.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default function Layout({ className, children }) {
<div className={ clsx( 'a-layout', className ) }>
<Header />
<main>
{ children && children }
{ children }
<LabsBanner />
<Footer />
</main>
Expand Down
2 changes: 1 addition & 1 deletion ecommerce-store-website/src/ui/components/button/button.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export default function Button( props ) {
function ButtonGroup({ children, className }) {
return (
<div className={ clsx( styles[ 'c-button-group' ], className )}>
{ children && children }
{ children }
</div>
);
}
Expand Down
2 changes: 1 addition & 1 deletion ecommerce-store-website/src/ui/components/card/card.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const Card = React.memo( function Card( props ) {
<div className={ styles[ 'c-card_image' ] } role='img' style={ bgImgStyles } />
)}
<div className={ styles[ 'c-card_wrapper' ]}>
{ children && children }
{ children }
</div>
</>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ $box-shadow-high: 2px 12px 24px -2px rgba( 0, 0, 0, 0.15 );

&_image {
position: relative;
background-repeat: no-repeat;
border-top-right-radius: grid-baseline(0.5);
border-top-left-radius: grid-baseline(0.5);
background-color: color-get( --text, 0.3 );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export default function FieldInput( props ) {
} else {
fieldProps = {
value,
...props?.onChange && { onChange: props.onChange },
...props.onChange && { onChange: props.onChange },
};
fieldMeta = {
error,
Expand Down
2 changes: 1 addition & 1 deletion ecommerce-store-website/src/ui/components/icon/icon.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion ecommerce-store-website/src/ui/components/tag/tag.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export default function Tag({ className, children, size }) {

return (
<span className={ clsx( styles[ 'c-tag' ], className, { [ styles[ `-size-${ size }` ] ]:size } ) }>
{ children && children }
{ children }
</span>
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default function VisuallyHidden({ className, children }) {

return (
<span className={ clsx( styles[ 'c-visually-hidden' ], className ) }>
{ children && children }
{ children }
</span>
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import _ from 'lodash-es';


function formatPropertyValue( pv ) {
return pv.trim().replace( /^"|"$/g, '' );
return pv.trim().replace("/^"|"$/g","");
}

export function getPropertyValue( propertyValue ) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export default function DemoHeader({ className, headline, children }) {
<h1 className="-mt0">{ headline }</h1>
</div>
<div className="grid -g-cols-1 -hide-s">
{ children && children }
{ children }
</div>
</section>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import styles from "./demo-hero.module.scss";
export default function DemoHero({ children, className, ...rest }) {
return (
<Hero className={ clsx( styles[ 's-demo-hero' ], className ) } { ...rest }>
{ children && children }
{ children }
</Hero>
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const TokenContextProvider = (props) => {

const { selectedTokens } = tokens;

tokenKeys.map((token) => {
tokenKeys.forEach((token) => {

selectedTokensState.push(...tokens.selectedTokens[token].tokens);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ export default function BookingModal({room}) {
disableEnforceFocus={true}
open={open}
onClose={handleClose}
disableEnforceFocus={true}
aria-labelledby="form-dialog-title">
{
bookingDone &&
Expand Down Expand Up @@ -253,7 +252,6 @@ export default function BookingModal({room}) {
className="paynow"
variant="contained"
onClick={useToken}
color="primary"
>
Use Token
</Button>
Expand All @@ -265,7 +263,6 @@ export default function BookingModal({room}) {
className="paynow"
variant="contained"
onClick={useToken}
color="primary"
>
<div className="lds-ellipsis"><div></div><div></div><div></div><div></div></div>
</Button>
Expand All @@ -277,7 +274,6 @@ export default function BookingModal({room}) {
className="paynow"
variant="contained"
onClick={handleSubmit}
color="primary"
>
Pay Now
</Button>
Expand All @@ -289,7 +285,6 @@ export default function BookingModal({room}) {
className="paynow"
variant="contained"
onClick={handleSubmit}
color="primary"
>
Pay Now (no discount)
</Button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ header {
margin: 0;
padding-top: 21px;
height: 32px;
font-family: SerifGothicStd;
font-family: SerifGothicStd, Arial, Helvetica, sans-serif;
font-size: 29px;
font-weight: bold;
font-stretch: normal;
Expand All @@ -25,12 +25,11 @@ header {

.logo h2 {
-webkit-font-smoothing: antialiased;
margin: 0;
padding-top: 0;
width: 118px;
height: 12px;
margin: 2px 36px 0;
font-family: SerifGothicStd;
font-family: SerifGothicStd, Arial, Helvetica, sans-serif;
font-size: 10px;
font-weight: bold;
font-stretch: normal;
Expand Down
2 changes: 1 addition & 1 deletion hotel-bogota-passive-negotiation-website/src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ function App() {

window.negotiator.on('tokens', (issuerTokens) => {
let tokens = [];
tokenIssuers.map((issuer) => {
tokenIssuers.forEach((issuer) => {
tokens.push(...issuerTokens[issuer.collectionID].tokens);
});
if (tokens.length > 0) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
.title {
font-size: 1.2rem;
margin-bottom: 0px;
padding-bottom: 0;
padding: 17px 24px 0px 24px !important
padding: 17px 24px 0px 24px !important;
}
.subTitle {
font-size: 1rem;
Expand Down
2 changes: 1 addition & 1 deletion ticket-issuer-url-website/src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ function App() {

let tokens = [];

tokenIssuers.map((issuer) => {
tokenIssuers.forEach((issuer) => {

tokens.push(...issuerTokens[issuer.collectionID].tokens);

Expand Down

0 comments on commit 2ec44ac

Please sign in to comment.