Bugfix: Fix copy in agent availability status (#466)

Copy update for agent status
This commit is contained in:
Pranav Raj S 2020-02-05 11:56:33 +05:30 committed by GitHub
parent 83b0bb4062
commit 607fc25723
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 4 deletions

View file

@ -10,7 +10,7 @@ describe('#getAvailableAgentsText', () => {
it('returns the correct text is there are two online agents', () => { it('returns the correct text is there are two online agents', () => {
expect( expect(
getAvailableAgentsText([{ name: 'Pranav' }, { name: 'Nithin' }]) getAvailableAgentsText([{ name: 'Pranav' }, { name: 'Nithin' }])
).toEqual('Pranav and Nithin is available'); ).toEqual('Pranav and Nithin are available');
}); });
it('returns the correct text is there are more than two online agents', () => { it('returns the correct text is there are more than two online agents', () => {

View file

@ -1,4 +1,3 @@
/* eslint-disable import/prefer-default-export */
export const isEmptyObject = obj => export const isEmptyObject = obj =>
Object.keys(obj).length === 0 && obj.constructor === Object; Object.keys(obj).length === 0 && obj.constructor === Object;
@ -28,7 +27,7 @@ export const getAvailableAgentsText = (agents = []) => {
if (count === 2) { if (count === 2) {
const [first, second] = agents; const [first, second] = agents;
return `${first.name} and ${second.name} is available`; return `${first.name} and ${second.name} are available`;
} }
const [agent] = agents; const [agent] = agents;

View file

@ -4,5 +4,5 @@ $twitter = Twitty::Facade.new do |config|
config.access_token = ENV.fetch('TWITTER_ACCESS_TOKEN', nil) config.access_token = ENV.fetch('TWITTER_ACCESS_TOKEN', nil)
config.access_token_secret = ENV.fetch('TWITTER_ACCESS_TOKEN_SECRET', nil) config.access_token_secret = ENV.fetch('TWITTER_ACCESS_TOKEN_SECRET', nil)
config.base_url = 'https://api.twitter.com' config.base_url = 'https://api.twitter.com'
config.environment = 'chatwootstaging' config.environment = ENV.fetch('TWITTER_ENVIRONMENT', '')
end end