diff options
author | cel <cel@f/6sQ6d2CMxRUhLpspgGIulDxDCwYD7DzFzPNr7u5AU=.ed25519> | 2017-05-29 06:38:49 -1000 |
---|---|---|
committer | cel <cel@f/6sQ6d2CMxRUhLpspgGIulDxDCwYD7DzFzPNr7u5AU=.ed25519> | 2017-05-30 09:58:53 -1000 |
commit | 35a3dedeb8b9670721bd363031083cc2c90fa085 (patch) | |
tree | 96fca1e6767d22556f096ab8bb535aa2cfbe2265 /lib/app.js | |
parent | 9e859f9fe19da67e9688bd4310bd2bae75b3d5c1 (diff) | |
download | patchfoo-35a3dedeb8b9670721bd363031083cc2c90fa085.tar.gz patchfoo-35a3dedeb8b9670721bd363031083cc2c90fa085.zip |
Implement custom emoji rendering and uploading
Diffstat (limited to 'lib/app.js')
-rw-r--r-- | lib/app.js | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -38,6 +38,7 @@ function App(sbot, config) { this._getAbout.bind(this)) this.unboxContent = memo({cache: lru(100)}, sbot.private.unbox) this.reverseNameCache = lru(500) + this.reverseEmojiNameCache = lru(500) this.unboxMsg = this.unboxMsg.bind(this) @@ -233,6 +234,10 @@ App.prototype.getReverseNameSync = function (name) { return id } +App.prototype.getReverseEmojiNameSync = function (name) { + return this.reverseEmojiNameCache.get(name) +} + App.prototype.getNameSync = function (name) { var about = this.aboutCache.get(name) return about && about.name |