From cbbaa5d0e4068d6923fb642a08dcf6079c8b03b6 Mon Sep 17 00:00:00 2001 From: David Baynard Date: Sun, 7 Mar 2021 21:29:38 +0000 Subject: [PATCH] Attempt to fix indexing undefined on iOS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is a really stupid fix that shouldn’t work and probably won’t. It’s worth a shot, though. Attempts to fix CROSSWRD-6 --- crosswrd-app/src/common/Reference.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crosswrd-app/src/common/Reference.tsx b/crosswrd-app/src/common/Reference.tsx index 6366c5d..6c0a314 100644 --- a/crosswrd-app/src/common/Reference.tsx +++ b/crosswrd-app/src/common/Reference.tsx @@ -7,8 +7,8 @@ export const Reference = Record<{ x: bigint; y: bigint }>( const centre = Reference(); export type Reference = typeof centre; -export const rotate180 = (r: Reference): Reference => - Reference({ x: -r.x, y: -r.y }); +export const rotate180 = ({ x, y }: Reference): Reference => + Reference({ x: -x, y: -y }); export const matchingRefs = (r: Reference): Set => Set([r, rotate180(r)]);