From 5f7966d984ad175071ada0787651d75276418d98 Mon Sep 17 00:00:00 2001 From: familyfriendlymikey Date: Mon, 15 Aug 2022 15:46:22 -0400 Subject: [PATCH] ensure frequency gets incremented on link click/return --- app/client.imba | 7 ++++--- package.json | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app/client.imba b/app/client.imba index 6a628a5..f14dbbb 100644 --- a/app/client.imba +++ b/app/client.imba @@ -169,7 +169,8 @@ tag app err "adding link", e def handle_click_link link - increment_link_frequency link + await increment_link_frequency link + window.location.href = "//{link.url}" def handle_click_search increment_search_engine_frequency! @@ -179,7 +180,7 @@ tag app use_search_engine! else let link = state.scored_links[selection_index] - increment_link_frequency link + await increment_link_frequency link window.location.href = "//{link.url}" def handle_click_add @@ -390,7 +391,7 @@ tag app <.link-left> diff --git a/package.json b/package.json index d9816fc..cddb35d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "fuzzyhome", - "version": "0.1.2", + "version": "0.1.3", "scripts": { "start": "imba run -SMH --baseurl . -w server.imba", "build-app": "rm -rf dist && imba build -SMH --baseurl . server.imba",