Skip to content

Instantly share code, notes, and snippets.

View Cargo.toml
[package]
name = "registrations"
version = "0.1.0"
authors = ["[your_name] <[your_email]>"]
edition = "2018"
[dependencies]
ink_primitives = { version = "3.0.0-rc2", default-features = false }
ink_metadata = { version = "3.0.0-rc2", default-features = false, features = ["derive"], optional = true }
ink_env = { version = "3.0.0-rc2", default-features = false }
@morkeltry
morkeltry / Contract1.sol
Last active May 27, 2020 11:48
Remix IDE v0.10.1 bug in transacting on VM deployed contracts
View Contract1.sol
pragma solidity ^0.6.0;
contract Number1 {
mapping (bytes32 => bytes32[]) dataCache;
uint8 thisContract = 1;
bytes32 isDifferentFromTheOther;
function dumpDataCache (bytes32 anything) public returns (string memory, uint256, bytes32[] memory) {
return ("Contract 1 returns:", thisContract, dataCache[anything]);
@morkeltry
morkeltry / bucket_policy.js
Created March 1, 2020 21:20 — forked from philfreo/bucket_policy.js
AWS S3 bucket policy to make all files public (+CORS)
View bucket_policy.js
{
"Statement": [
{
"Sid": "AllowPublicRead",
"Effect": "Allow",
"Principal": {
"AWS": "*"
},
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::bucket_name_here/*"