mirror of
https://github.com/AustinKelsay/plebdevs.git
synced 2025-06-01 14:52:02 +00:00
clean up unused
This commit is contained in:
parent
86f010cf62
commit
38bb4b79cd
@ -20,11 +20,8 @@ const MDDisplay = dynamic(() => import('@uiw/react-markdown-preview'), {
|
||||
|
||||
const CourseLesson = ({ lesson, course, decryptionPerformed, isPaid, setCompleted }) => {
|
||||
const [zapAmount, setZapAmount] = useState(0);
|
||||
const [nAddress, setNAddress] = useState(null);
|
||||
const { zaps, zapsLoading, zapsError } = useZapsQuery({
|
||||
event: lesson,
|
||||
type: 'lesson',
|
||||
});
|
||||
const { zaps, zapsLoading, zapsError } = useZapsQuery({ event: lesson,
|
||||
type: 'lesson' });
|
||||
const { returnImageProxy } = useImageProxy();
|
||||
const menuRef = useRef(null);
|
||||
const toastRef = useRef(null);
|
||||
@ -116,18 +113,6 @@ const CourseLesson = ({ lesson, course, decryptionPerformed, isPaid, setComplete
|
||||
}
|
||||
}, [isCompleted, isTracking, lesson.id, setCompleted]);
|
||||
|
||||
useEffect(() => {
|
||||
if (lesson) {
|
||||
const addr = nip19.naddrEncode({
|
||||
pubkey: lesson.pubkey,
|
||||
kind: lesson.kind,
|
||||
identifier: lesson.d,
|
||||
relays: appConfig.defaultRelayUrls,
|
||||
});
|
||||
setNAddress(addr);
|
||||
}
|
||||
}, [lesson]);
|
||||
|
||||
const renderContent = () => {
|
||||
if (isPaid && decryptionPerformed) {
|
||||
return <MDDisplay className="p-4 rounded-lg w-full" source={lesson.content} />;
|
||||
|
Loading…
x
Reference in New Issue
Block a user