Skip to content

corrected the organisation to organization #158

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/popup.html
Original file line number Diff line number Diff line change
Expand Up @@ -132,19 +132,19 @@ <h6 class="text-base font-semibold">Scrum Report</h6>
<div id="settingsSection" class="tab-content hidden">
<div class="">
<div class="flex items-center mt-4">
<h4>Organisation Name</h4>
<h4>Organization Name</h4>
<span class="tooltip-container ml-2">
<i class="fa fa-question-circle question-icon"></i>
<span class="tooltip-bubble">
<b>Which organisation's GitHub activity?</b><br>
Enter the GitHub organisation name to fetch activites for. Default is <b>fossasia</b>.
Organisation name is not case-sensitive.
<b>Which organization's GitHub activity?</b><br>
Enter the GitHub organization name to fetch activites for. Default is <b>fossasia</b>.
Organization name is not case-sensitive.
</span>
</span>
</div>
<input id="orgInput" type="text"
class="w-full border-2 border-gray-200 bg-gray-200 rounded-xl text-gray-800 p-2 my-2"
placeholder="Enter organisation name (default: fossasia)">
placeholder="Enter organization name (default: fossasia)">
</div>
<div class="">
<div class="flex items-center justify-between">
Expand Down
10 changes: 5 additions & 5 deletions src/scripts/popup.js
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ document.addEventListener('DOMContentLoaded', function () {
.then(res => {
console.log('[Org Check] Response status for', org, ':', res.status);
if (res.status === 404) {
console.log('[Org Check] Organisation not found on GitHub:', org);
console.log('[Org Check] Organization not found on GitHub:', org);
// Remove any existing toast with the same id
const oldToast = document.getElementById('invalid-org-toast');
if (oldToast) oldToast.parentNode.removeChild(oldToast);
Expand All @@ -387,7 +387,7 @@ document.addEventListener('DOMContentLoaded', function () {
toastDiv.style.left = '50%';
toastDiv.style.transform = 'translateX(-50%)';
toastDiv.style.zIndex = '9999';
toastDiv.innerText = 'Organisation not found on GitHub.';
toastDiv.innerText = 'Organization not found on GitHub.';
document.body.appendChild(toastDiv);
setTimeout(() => {
if (toastDiv.parentNode) toastDiv.parentNode.removeChild(toastDiv);
Expand All @@ -398,14 +398,14 @@ document.addEventListener('DOMContentLoaded', function () {
// Remove any existing toast with the same id (for valid orgs)
const oldToast = document.getElementById('invalid-org-toast');
if (oldToast) oldToast.parentNode.removeChild(oldToast);
console.log('[Org Check] Organisation exists on GitHub:', org);
console.log('[Org Check] Organization exists on GitHub:', org);
// Valid org: update storage and fetch data
chrome.storage.local.set({ orgName: org }, function () {
if (window.generateScrumReport) window.generateScrumReport();
});
})
.catch((err) => {
console.log('[Org Check] Error validating organisation:', org, err);
console.log('[Org Check] Error validating organization:', org, err);
// Remove any existing toast with the same id
const oldToast = document.getElementById('invalid-org-toast');
if (oldToast) oldToast.parentNode.removeChild(oldToast);
Expand All @@ -423,7 +423,7 @@ document.addEventListener('DOMContentLoaded', function () {
toastDiv.style.left = '50%';
toastDiv.style.transform = 'translateX(-50%)';
toastDiv.style.zIndex = '9999';
toastDiv.innerText = 'Error validating organisation.';
toastDiv.innerText = 'Error validating organization.';
document.body.appendChild(toastDiv);
setTimeout(() => {
if (toastDiv.parentNode) toastDiv.parentNode.removeChild(toastDiv);
Expand Down
4 changes: 2 additions & 2 deletions src/scripts/scrumHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -381,9 +381,9 @@ function allIncluded(outputTarget = 'email') {

if (issuesRes.status === 404 || prRes.status === 404) {
if (outputTarget === 'popup') {
Materialize.toast && Materialize.toast('Organisation not found on GitHub', 3000);
Materialize.toast && Materialize.toast('Organization not found on GitHub', 3000);
}
throw new Error('Organisation not found');
throw new Error('Organization not found');
}

if (!issuesRes.ok) throw new Error(`Error fetching Github issues: ${issuesRes.status} ${issuesRes.statusText}`);
Expand Down