toJson method

List toJson()

Returns the contact list as a JSON array of event tags.

Implementation

List<dynamic> toJson() {
  List<dynamic> result = [];
  for (Contact contact in _contacts.values) {
    result.add(["p", contact.publicKey, contact.url, contact.petname]);
  }
  return result;
}