This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rails_helper' | |
describe 'paper_trail' do | |
before { Rails.application.eager_load! } | |
let(:excluded_classes) { [ActiveRecord::SchemaMigration, PaperTrail::Version, PaperTrail::VersionAssociation] } | |
let(:models) { ActiveRecord::Base.descendants - excluded_classes } | |
it 'is implemented in all ActiveRecord::Base models' do | |
expect(models).to all(respond_to(:paper_trail_options)) | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Verifying my Blockstack ID is secured with the address 1EEQfALCUFNQ6EYMPx2KfytxgdVTtJbAZd https://explorer.blockstack.org/address/1EEQfALCUFNQ6EYMPx2KfytxgdVTtJbAZd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
debugShowCheckedModeBanner: false, | |
home: Scaffold( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:convert'; | |
import 'dart:typed_data'; | |
void main() { | |
String input = ""; | |
Uint8List hexDecoded = hexToBytes(input); | |
Uint8List base64Decoded = base64Decode(hexDecoded); | |
String hexEncoded = bytesToHex(base64Decoded); | |
print(hexEncoded); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:convert'; | |
// Utility to convert base64-encoded strings to hex | |
void main() { | |
String base64PublicKey = ""; | |
print(base64Decode(base64PublicKey) | |
.map((e) => e.toRadixString(16).padLeft(2, '0')) | |
.join()); | |
} |
OlderNewer