Skip to content
Snippets Groups Projects
Commit 3bb2e91d authored by lain's avatar lain
Browse files

Return empty auth header when we don't have a user.

parent 7c201810
Branches
Tags
No related merge requests found
......@@ -14,7 +14,13 @@ const MEDIA_UPLOAD_URL = '/api/statusnet/media/upload'
// import { param, ajax } from 'jquery';
// import { merge } from 'lodash';
const authHeaders = (user) => ({ 'Authorization': `Basic ${btoa(`${user.username}:${user.password}`)}` })
const authHeaders = (user) => {
if (user) {
return { 'Authorization': `Basic ${btoa(`${user.username}:${user.password}`)}` }
} else {
return { }
}
}
const fetchTimeline = ({timeline, credentials, since = false, until = false}) => {
const timelineUrls = {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment