added block type filter for public get blocks endpoint
This commit is contained in:
parent
02cdbc75ce
commit
68a557daf5
4 changed files with 29 additions and 26 deletions
|
@ -1,9 +1,12 @@
|
|||
'''
|
||||
Onionr - Private P2P Communication
|
||||
"""Onionr - Private P2P Communication.
|
||||
|
||||
Load the user's inbox and return it as a list
|
||||
'''
|
||||
'''
|
||||
Load the user's inbox and return it as a list
|
||||
"""
|
||||
from onionrblocks import onionrblockapi
|
||||
from coredb import blockmetadb
|
||||
from utils import reconstructhash, identifyhome
|
||||
import deadsimplekv as simplekv
|
||||
"""
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
|
@ -16,12 +19,9 @@
|
|||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
'''
|
||||
from onionrblocks import onionrblockapi
|
||||
from coredb import blockmetadb
|
||||
import filepaths
|
||||
from utils import reconstructhash, identifyhome
|
||||
import deadsimplekv as simplekv
|
||||
"""
|
||||
|
||||
|
||||
def load_inbox():
|
||||
inbox_list = []
|
||||
deleted = simplekv.DeadSimpleKV(identifyhome.identify_home() + '/mailcache.dat').get('deleted_mail')
|
||||
|
@ -33,4 +33,4 @@ def load_inbox():
|
|||
block.decrypt()
|
||||
if block.decrypted and reconstructhash.deconstruct_hash(blockHash) not in deleted:
|
||||
inbox_list.append(blockHash)
|
||||
return inbox_list
|
||||
return inbox_list
|
||||
|
|
|
@ -14,8 +14,8 @@
|
|||
"hide_created_blocks": true,
|
||||
"insert_deniable_blocks": true,
|
||||
"max_block_age": 2678400,
|
||||
"minimum_block_pow": 6,
|
||||
"minimum_send_pow": 6,
|
||||
"minimum_block_pow": 4,
|
||||
"minimum_send_pow": 4,
|
||||
"public_key": "",
|
||||
"random_bind_ip": true,
|
||||
"security_level": 0,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue