Skip to content

Commit

Permalink
fix: popup message handler isNaN global
Browse files Browse the repository at this point in the history
  • Loading branch information
Maurier committed Jul 3, 2024
1 parent 21a8f45 commit cad6d2d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/components/new-submission/cz.new-submission.vue
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@
>
<v-card class="py-4" color="primary" dark>
<v-card-text>
<p id="new-submission-saving" class="mb-2 text-center">
<p id="new-submission-saving" class="mb-4 text-center text-body-2">
Saving...
</p>
<v-progress-linear
Expand Down
5 changes: 2 additions & 3 deletions src/components/register-dataset/cz.register-dataset.vue
Original file line number Diff line number Diff line change
Expand Up @@ -375,8 +375,7 @@

<v-btn
v-else
color="primary"
class="mr-4"
class="mr-4 bg-primary"
:disabled="isFetching || !isValid || !url"
@click="goToEditSubmission"
>
Expand Down Expand Up @@ -559,7 +558,7 @@ class CzRegisterDataset extends mixins(ActiveRepositoryMixin) {
this.selectedRepository.key,
)
if (response && Number.isNaN(response)) {
if (response && isNaN(response)) {
this.submission = Submission.getInsertData(
response.metadata,
this.selectedRepository.key,
Expand Down
2 changes: 1 addition & 1 deletion src/models/repository.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ export default class Repository extends Model implements IRepository {
callback?: () => any,
) {
const handleMessage = async (event: MessageEvent) => {
if (event.origin !== APP_URL || !Object.prototype.hasOwnProperty.call(!event.data, 'token'))
if (event.origin !== APP_URL || !Object.prototype.hasOwnProperty.call(event.data, 'token'))
return

if (activeRepository && event.data?.token) {
Expand Down

0 comments on commit cad6d2d

Please sign in to comment.