aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-10-12 15:26:04 +0200
committerChocobozzz <me@florianbigard.com>2018-10-16 16:41:36 +0200
commit7ad9b9846c44d198a736183fb186c2039f5236b5 (patch)
tree9c8456882a261c0522efb507f20e323c2741a0f8 /shared/models
parentdffd5d127f49eb63d2b2b3133aec75ec1d7e4dcb (diff)
downloadPeerTube-7ad9b9846c44d198a736183fb186c2039f5236b5.tar.gz
PeerTube-7ad9b9846c44d198a736183fb186c2039f5236b5.tar.zst
PeerTube-7ad9b9846c44d198a736183fb186c2039f5236b5.zip
Add ability for users to block an account/instance on server side
Diffstat (limited to 'shared/models')
-rw-r--r--shared/models/blocklist/account-block.model.ts7
-rw-r--r--shared/models/blocklist/index.ts2
-rw-r--r--shared/models/blocklist/server-block.model.ts9
-rw-r--r--shared/models/index.ts1
4 files changed, 19 insertions, 0 deletions
diff --git a/shared/models/blocklist/account-block.model.ts b/shared/models/blocklist/account-block.model.ts
new file mode 100644
index 000000000..d6f8840c5
--- /dev/null
+++ b/shared/models/blocklist/account-block.model.ts
@@ -0,0 +1,7 @@
1import { Account } from '../actors'
2
3export interface AccountBlock {
4 byAccount: Account
5 accountBlocked: Account
6 createdAt: Date | string
7}
diff --git a/shared/models/blocklist/index.ts b/shared/models/blocklist/index.ts
new file mode 100644
index 000000000..fc7873270
--- /dev/null
+++ b/shared/models/blocklist/index.ts
@@ -0,0 +1,2 @@
1export * from './account-block.model'
2export * from './server-block.model'
diff --git a/shared/models/blocklist/server-block.model.ts b/shared/models/blocklist/server-block.model.ts
new file mode 100644
index 000000000..efba672bd
--- /dev/null
+++ b/shared/models/blocklist/server-block.model.ts
@@ -0,0 +1,9 @@
1import { Account } from '../actors'
2
3export interface ServerBlock {
4 byAccount: Account
5 serverBlocked: {
6 host: string
7 }
8 createdAt: Date | string
9}
diff --git a/shared/models/index.ts b/shared/models/index.ts
index e61d6cbdc..062533834 100644
--- a/shared/models/index.ts
+++ b/shared/models/index.ts
@@ -1,6 +1,7 @@
1export * from './activitypub' 1export * from './activitypub'
2export * from './actors' 2export * from './actors'
3export * from './avatars' 3export * from './avatars'
4export * from './blocklist'
4export * from './redundancy' 5export * from './redundancy'
5export * from './users' 6export * from './users'
6export * from './videos' 7export * from './videos'