From c3233c33a5e8c5ae22c83cadb14fe64a66170053 Mon Sep 17 00:00:00 2001
From: Laila Los <44241786+ElectronicBlueberry@users.noreply.github.com>
Date: Mon, 16 Jan 2023 14:13:06 +0100
Subject: [PATCH] run prettier update pre-commit hook
---
.pre-commit-config.yaml.sample | 4 +++-
client/src/mvc/ui/ui-modal.js | 5 +----
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/.pre-commit-config.yaml.sample b/.pre-commit-config.yaml.sample
index 0523e68b2120..8de06e003145 100644
--- a/.pre-commit-config.yaml.sample
+++ b/.pre-commit-config.yaml.sample
@@ -8,11 +8,13 @@ repos:
hooks:
- id: flake8
- repo: https://github.com/pre-commit/mirrors-prettier
- rev: v2.6.0 # Use the sha or tag you want to point at
+ rev: v2.7.1 # Use the sha or tag you want to point at
hooks:
- id: prettier
types: [file]
types_or: [javascript, jsx, ts, tsx, vue]
+ additional_dependencies:
+ - prettier@2.8.3 # Workaround. See https://github.com/pre-commit/mirrors-prettier/issues/29
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0 # Use the ref you want to point at
hooks:
diff --git a/client/src/mvc/ui/ui-modal.js b/client/src/mvc/ui/ui-modal.js
index e36f52e199d4..cae8e5eb3415 100644
--- a/client/src/mvc/ui/ui-modal.js
+++ b/client/src/mvc/ui/ui-modal.js
@@ -108,10 +108,7 @@ export var View = Backbone.View.extend({
if (this.options.buttons) {
var counter = 0;
$.each(this.options.buttons, (name, callback) => {
- var $button = $("")
- .attr("id", `button-${counter++}`)
- .text(name)
- .click(callback);
+ var $button = $("").attr("id", `button-${counter++}`).text(name).click(callback);
self.$buttons.append($button).append(" ");
self.buttonList[name] = $button;
});