pressing enter without input results in player search failure
This commit is contained in:
1 parent
75803edfe7
commit
c7c267b2a1
1 file changed
+3
-1
@@ -168,7 +168,9 @@ selectPlayerPrompt pStr callback = Prompt
|
|||||||
sel
|
sel
|
||||||
C.moveCursor row col
|
C.moveCursor row col
|
||||||
, promptCharCheck = const True
|
, promptCharCheck = const True
|
||||||
, promptAction = \sStr -> do
|
, promptAction = \sStr -> if null sStr
|
||||||
|
then callback Nothing
|
||||||
|
else do
|
||||||
players <- gets $ view $ database.dbPlayers
|
players <- gets $ view $ database.dbPlayers
|
||||||
case playerSearchExact sStr players of
|
case playerSearchExact sStr players of
|
||||||
Just (n, _) -> callback $ Just n
|
Just (n, _) -> callback $ Just n
|
||||||
|
|||||||
Reference in new issue
Block a user