Răsfoiți Sursa

rename func

Shun Miyazawa 4 ani în urmă
părinte
comite
292a9e2862
1 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 2 2
      packages/app/src/components/SubscribeButton.jsx

+ 2 - 2
packages/app/src/components/SubscribeButton.jsx

@@ -14,7 +14,7 @@ const SubscruibeButton = (props) => {
 
   const { appContainer, pageContainer } = props;
 
-  const handleClick = async() => {
+  const Subscribe = async() => {
     try {
       const res = await appContainer.apiv3Put('page/subscribe', { pageId: pageContainer.state.pageId, status: !isWatching });
       if (res) {
@@ -32,7 +32,7 @@ const SubscruibeButton = (props) => {
       <button
         type="button"
         id="subscribe-button"
-        onClick={handleClick}
+        onClick={Subscribe}
         className={`btn btn-watch border-0 ${`btn-${props.size}`} ${isWatching ? 'active' : ''} `}
       >
         {isWatching && (