Skip to content

Commit

Permalink
Hide info QA console logs by default
Browse files Browse the repository at this point in the history
  • Loading branch information
leomendoza123 committed Jul 22, 2021
1 parent 00d510a commit 47baeb7
Show file tree
Hide file tree
Showing 11 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion cors-anywhere.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ cors_proxy
},
})
.listen(port, host, function () {
console.info('Running CORS Anywhere on ' + host + ':' + port)
console.debug('Running CORS Anywhere on ' + host + ':' + port)
})
2 changes: 1 addition & 1 deletion cypress/support/google-analytics.commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Cypress.on('window:before:load', (win) => {
cy.stub(win.dataLayer, 'push')
.withArgs(isNotAnInternalGtagCall)
.callsFake((args) => {
console.info(args)
console.debug(args)
})
.as('ga')
})
Expand Down
2 changes: 1 addition & 1 deletion scripts/browserlist.prebuild.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ fs.writeFile(
if (err) {
throw new Error('Error creating browserlist regexp ' + err)
}
console.info('Browserlist regexp created')
console.debug('Browserlist regexp created')
}
)
2 changes: 1 addition & 1 deletion scripts/lighthouse/firebase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export class FirebaseManager {
.doc(id)
.set(result)
.then(function (docRef) {
console.info('Document written with ID: ', JSON.stringify(docRef))
console.debug('Document written with ID: ', JSON.stringify(docRef))
})
.catch(function (error) {
console.error('Error adding document: ', error)
Expand Down
12 changes: 6 additions & 6 deletions scripts/properties-folder-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ abstract class PropertyFolderImpl implements PropertyFolder {
flatFolder = true,
reportUnexistingFiles?: (path: string, languageCode: string) => void
) {
console.info(`Read folder ${folderPath} ________`)
console.debug(`Read folder ${folderPath} ________`)
this.folderPath = folderPath
this.reportUnexistingFiles = reportUnexistingFiles
this.propertiesFolderToJson(folderPath, flatFolder)
Expand Down Expand Up @@ -91,7 +91,7 @@ abstract class PropertyFolderImpl implements PropertyFolder {
It only copies the translations when there is not translation on this PropertyFolder
*/
cloneValues(originFolder: PropertyFolderImpl): PropertyFolder {
console.info('Clone values from properties ________')
console.debug('Clone values from properties ________')
const matchingProperties: MatchingPair[] = this.matchingValueEnglishProperties(
originFolder
)
Expand Down Expand Up @@ -348,16 +348,16 @@ From the many properties on Orcid Source that have the same english value of ${p
}

generateTestingLanguages() {
console.info('Generate testing languages ________')
console.debug('Generate testing languages ________')
const testingLanguages = ['rl', 'lr', 'xx']

Object.keys(this.files).forEach((fileName) => {
console.info('fileName', fileName)
console.debug('fileName', fileName)
testingLanguages.forEach((testingLangue) => {
console.info('---testingLangue', testingLangue)
console.debug('---testingLangue', testingLangue)
// Create the error testing language if does not exist
if (!this.files[fileName][testingLangue]) {
console.info('---did not had translations file', testingLangue)
console.debug('---did not had translations file', testingLangue)

this.files[fileName][testingLangue] = {}
}
Expand Down
6 changes: 3 additions & 3 deletions src/app/core/google-analytics/google-analytics.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export class GoogleAnalyticsService {

reportPageView(url: string) {
if (environment.debugger) {
console.info(`GA - Navigation ${url}`)
console.debug(`GA - Navigation ${url}`)
}
this.gtag('config', environment.GOOGLE_ANALYTICS, {
cookie_flags: 'SameSite=None;Secure',
Expand All @@ -38,7 +38,7 @@ export class GoogleAnalyticsService {
const duration = this.finishPerformanceMeasurement(url)
if (duration) {
if (environment.debugger) {
console.info(`GA - Took ${duration} to load ${url}`)
console.debug(`GA - Took ${duration} to load ${url}`)
}
this.gtag('event', 'timing_complete', {
name: this.removeUrlParameters(url),
Expand Down Expand Up @@ -72,7 +72,7 @@ fatal: "${fatal}"
event_label = 'OAuth ' + this.buildClientString(event_label)
}
if (environment.debugger) {
console.info(`GA - Event /${event_category}/${action}/${event_label}/`)
console.debug(`GA - Event /${event_category}/${action}/${event_label}/`)
}
return this.eventObservable(action, {
event_category,
Expand Down
2 changes: 1 addition & 1 deletion src/app/core/record/record.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export class RecordService {
this.recordSubject$ = new ReplaySubject<UserRecord>(1)
if (environment.debugger) {
this.recordSubject$.subscribe((value) => {
console.info(value)
console.debug(value)
})
}

Expand Down
4 changes: 2 additions & 2 deletions src/app/core/user/user.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ export class UserService {
map((data) => this.computesUpdatedUserData(data)),
// Debugger for the user session on development time
tap((session) =>
environment.debugger ? console.info(session) : null
environment.debugger ? console.debug(session) : null
),
tap((session) => {
this.$userSessionSubject.next(session)
Expand Down Expand Up @@ -288,7 +288,7 @@ export class UserService {
tap((session) => (this.keepRefreshingUserSession = !session.error)),
tap(() =>
environment.debugger
? console.info('Oauth session declare')
? console.debug('Oauth session declare')
: null
)
)
Expand Down
2 changes: 1 addition & 1 deletion src/app/guards/language.guard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export class LanguageGuard implements CanActivateChild {
// get language context
langContext = this.getLanguageContext(next.queryParams)
if (environment.debugger) {
console.info('language context', langContext)
console.debug('language context', langContext)
}
}),
switchMap(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ export class FundingStackComponent implements OnInit {

makePrimaryCard(funding: Funding) {
// TODO
console.info(this.stackPanelsDisplay)
console.debug(this.stackPanelsDisplay)
}

changeTopPanelOfTheStack(funding: Funding) {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="container">
<div
class="is-this-you orc-font-body-small"
*ngIf="isPublicRecord && !userStatus.loggedIn"
*ngIf="isPublicRecord && !userStatus?.loggedIn"
>
<mat-icon class="large-material-icon">account_circle</mat-icon>
<p i18n="@@record.isThisYou">Is this you?</p>
Expand Down

0 comments on commit 47baeb7

Please sign in to comment.