From bdec1732a9cc65db4d65ec1db2ad123b01c9d8cd Mon Sep 17 00:00:00 2001
From: Travis Ralston <travpc@gmail.com>
Date: Wed, 31 Jan 2018 11:19:35 -0700
Subject: [PATCH] Increase default lengths for URL previews

---
 config.sample.yaml                                          | 4 ++--
 src/github.com/turt2live/matrix-media-repo/config/config.go | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/config.sample.yaml b/config.sample.yaml
index 455c27fa..795900e5 100644
--- a/config.sample.yaml
+++ b/config.sample.yaml
@@ -94,11 +94,11 @@ urlPreviews:
   # Note: URL previews are limited to a given number of words, which are then limited to a number
   # of characters, taking off the last word if it needs to. This also applies for the title.
 
-  numWords: 30 # The number of words to include in a preview (maximum)
+  numWords: 50 # The number of words to include in a preview (maximum)
   maxLength: 200 # The maximum number of characters for a description
 
   numTitleWords: 30 # The maximum number of words to include in a preview's title
-  maxTitleLength: 100 # The maximum number of characters for a title
+  maxTitleLength: 150 # The maximum number of characters for a title
 
   # The mime types to preview when OpenGraph previews cannot be rendered. OpenGraph previews are
   # calculated on anything matching "text/*". To have a thumbnail in the preview the URL must be
diff --git a/src/github.com/turt2live/matrix-media-repo/config/config.go b/src/github.com/turt2live/matrix-media-repo/config/config.go
index 2f1271de..3ac71e3c 100644
--- a/src/github.com/turt2live/matrix-media-repo/config/config.go
+++ b/src/github.com/turt2live/matrix-media-repo/config/config.go
@@ -207,10 +207,10 @@ func NewDefaultConfig() *MediaRepoConfig {
 		},
 		UrlPreviews: &UrlPreviewsConfig{
 			Enabled:          true,
-			NumWords:         30,
+			NumWords:         50,
 			NumTitleWords:    30,
 			MaxLength:        200,
-			MaxTitleLength:   100,
+			MaxTitleLength:   150,
 			MaxPageSizeBytes: 10485760, // 10mb
 			NumWorkers:       10,
 			FilePreviewTypes: []string{
-- 
GitLab