From dbb9eea25f80e7984a112409863be5191af5bf5e Mon Sep 17 00:00:00 2001
From: Logan Hunt <loganhunt@simponic.xyz>
Date: Fri, 1 Apr 2022 16:04:00 -0600
Subject: Added way too much stuff

---
 client/components/map/chat_room_geoman.jsx | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

(limited to 'client/components/map/chat_room_geoman.jsx')

diff --git a/client/components/map/chat_room_geoman.jsx b/client/components/map/chat_room_geoman.jsx
index a39b45a..07d0a4c 100644
--- a/client/components/map/chat_room_geoman.jsx
+++ b/client/components/map/chat_room_geoman.jsx
@@ -2,6 +2,7 @@ import { useLeafletContext } from '@react-leaflet/core';
 import L from 'leaflet';
 import markerIconPng from 'leaflet/dist/images/marker-icon.png';
 import { useEffect, useContext, useState } from 'react';
+import toast from 'react-hot-toast';
 import { ApiContext } from '../../utils/api_context';
 
 const userPositionBubble = {
@@ -162,7 +163,12 @@ export const Geoman = ({ user, userPos, joinRoom }) => {
           longitude,
           radius: shape.layer.getRadius(),
         });
-        console.log(chatRoom);
+        if (chatRoom.error) {
+          toast.error(chatRoom.error);
+        } else if (chatRoom.id) {
+          toast.success('Chat room created');
+        }
+
         reRender();
       }
     });
-- 
cgit v1.2.3-70-g09d2

