• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kiva / ui / 15857960360

24 Jun 2025 05:59PM UTC coverage: 52.572% (+4.7%) from 47.876%
15857960360

push

github

emuvente
fix: add alt text for user avatar

1787 of 3592 branches covered (49.75%)

Branch coverage included in aggregate %.

1 of 1 new or added line in 1 file covered. (100.0%)

289 existing lines in 18 files now uncovered.

2628 of 4806 relevant lines covered (54.68%)

281.14 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/api/SnowplowSessionLink.js
1
import { setContext } from '@apollo/client/link/context/index';
2
import _set from 'lodash/set';
3

4
function getSPCookieSession(cookieStore) {
5
        // kiva specific sp cookie
6
        const sp = cookieStore.get('_sp_id.6d5c');
×
7
        // handle missing cookie
8
        if (typeof sp === 'undefined') {
×
9
                return '';
×
10
        }
11
        const spCookieArray = sp.split('.');
×
12
        // get last item in the array, our session id
13
        const sessionId = spCookieArray[spCookieArray.length - 1];
×
14
        return sessionId;
×
15
}
16

17
export default ({ cookieStore }) => {
18
        return setContext((operation, previousContext) => {
×
UNCOV
19
                if (!cookieStore) return previousContext;
×
20

21
                // fetch session id
22
                const spSessionId = getSPCookieSession(cookieStore);
×
23
                // pass along existing context if no session id exists
UNCOV
24
                if (spSessionId === '') {
×
UNCOV
25
                        return previousContext;
×
26
                }
27
                // add header to existing context and pass along
UNCOV
28
                return _set(previousContext, 'headers.X-Session-Id', spSessionId);
×
29
        });
30
};
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc