Skip to content

Instantly share code, notes, and snippets.

I'm happy these days.

Sahil Rajput sahilrajput03

I'm happy these days.
View GitHub Profile
View haq-se-single-magnet-link.txt
View a.js
// post hooks for inserMany<MovieDocument[]>('insertMany', async function (docs, next) {
console.log('docs POST =', docs);
if (Array.isArray(docs) && docs.length) {
const correctData = => {
console.log('singelDoc post before added =', JSON.stringify(singleDoc));
// If id AND name are present, then we can use them to generate the sort_name
if ( > 0 && {
View a.json
"subscriber": {
"email_address": "",
"payer_id": "VZXRX2AG4RY6G",
"name": {
"given_name": "BarBuyer",
"surname": "Jones"
"shipping_address": {
"name": {
View Learn Upgradable Smart

Upgradable contracts - UUPS (better than Transparent Proxy)

Source: Official Openzeppelin youtube channel

All resources related to Upgradability from Openzeppelin: Click here

Depending on where we put the upgradeTo() function we decide b/w two types of upgradable smart contracts.


sahilrajput03 / 721.sol
Created November 14, 2022 04:55
View 721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC721/ERC721.sol)
pragma solidity ^0.8.0;
import './IERC721.sol';
import './IERC721Receiver.sol';
import './extensions/IERC721Metadata.sol';
import '../../utils/Address.sol';
import '../../utils/Context.sol';